AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Client & Server Script for TCP/IP Network Communication
Goto page Previous  1, 2, 3, 4, 5, 6, 7
 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions
View previous topic :: View next topic  
Author Message
LYCOS17-NotLoggedIn
Guest





PostPosted: Thu May 22, 2008 5:00 am    Post subject: Reply with quote

Hi there. I am still having trouble.

So, you say if one of us runs the Server script configured like this below

(I am excerpting this from the original code in this thread)

Code:

; -------------------------------------------------
; ------------SERVERSCRIPT------------------
; -------------------------------------------------
; CONFIGURATION SECTION:

; Specify Your own Network's address and port.
Network_Address = 70.74.71.100
Network_Port = 8765



I am assuming from the comment on this code, I am to put my PUBLIC IP address in that Network_Address spot and a port I want to open.

And my friend runs the Client in another part of town,....

Code:

; -------------------------------------------------
;-----------CLIENTSCRIPT----------------------
; -------------------------------------------------
; CONFIGURATION SECTION:

; Specify address and port of the server.
Network_Address = 70.74.71.100
Network_Port = 8765


So, my buddy runs this part of the script... and that should have my PUBLIC IP and same port. ....and so then, upon him clicking CONNECT from the client script, it should reach my end, and connect to my server script?

Right? The problem I am facing is, when I run the Server script it just crashes. I am getting a bind() indicated Winsock error 10049 message. Same thing happens with him if he attempts to run the server script. However, I am not running nor my friend is running any firewalls and we are on the same ISP. Further, we can actually ping each other, and so from DOS when we PING each other we see data there at that level.... so there are no blocks in theory between us.

So what are we doing wrong? If I put something like 127.0.0.1 on the Server Script, it just sends messages to itself... that works.

..... Any ideas on what we could be doing wrong, and need to do to make this function over the Internet? Smile
Back to top
jmanx



Joined: 14 May 2008
Posts: 36

PostPosted: Thu May 22, 2008 5:50 am    Post subject: Reply with quote

either put 127.0.0.1 or your local IP address for the server
Back to top
View user's profile Send private message
Zippo()
Guest





PostPosted: Thu May 22, 2008 8:10 am    Post subject: Reply with quote

Lexikos wrote:
It seems Zippo() skipped over half my post. Rolling Eyes

I'll try to make it more obvious next time Razz
Back to top
Lexikos



Joined: 17 Oct 2006
Posts: 2544
Location: Australia, Qld

PostPosted: Thu May 22, 2008 9:26 am    Post subject: Reply with quote

jmanx wrote:
either put 127.0.0.1 or your local IP address for the server
IIRC, the address in the server is the address of the local interface it binds to. If it binds to localhost (127.0.0.1), it will only accept connections from the local machine. Binding to 0.0.0.0 on the other hand, should allow connections from any network.
Back to top
View user's profile Send private message
LYCOS17



Joined: 06 Feb 2008
Posts: 20
Location: Dallas

PostPosted: Thu May 22, 2008 4:56 pm    Post subject: Reply with quote

Thank you all! Now it works and I appreciate all the assistance.Very Happy
Back to top
View user's profile Send private message
U90
Guest





PostPosted: Fri May 23, 2008 12:12 am    Post subject: Reply with quote

jmanx wrote:
It works now thanks.
Is there anyway to define when a certain address disconnects though?


Hmm... interesting approach. I was thinking more functionally, disconnecting from the current client connected to. (I.e. path > press CONNECT to connect > DISCONNECT to disconnect > and CONNECT to reconnect, ... ) How would this be done?
Back to top
LYCOS17



Joined: 06 Feb 2008
Posts: 20
Location: Dallas

PostPosted: Wed Jun 04, 2008 7:39 pm    Post subject: Reply with quote

I am wondering if anyone has had luck prusing the notions U90 presented above. I think it would be very useful to have this capability inside this TCP/IP function, for re-connection to server without reloading script Smile
Back to top
View user's profile Send private message
Guest






PostPosted: Sun Jul 06, 2008 6:44 pm    Post subject: Reply with quote

Can anyone see if this last requests is possible? It seems like a easy to do thing, but appears to be harder in execution than it seems. Confused
Back to top
Guest






PostPosted: Sat Jul 12, 2008 7:57 pm    Post subject: Reply with quote

please? Embarassed Crying or Very sad , i would very much like to make this work for a project if anyone knows! Very Happy


Zebra.
Back to top
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions All times are GMT
Goto page Previous  1, 2, 3, 4, 5, 6, 7
Page 7 of 7

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group