JohnRichard Posted February 19, 2009 Author Share Posted February 19, 2009 Is this some kind of peer to peer project? Explain what you want to do , and not how. you want to do it.i'm running out of time manadar. i'll post to you in more details when i get home. Link to comment Share on other sites More sharing options...
jvanegmond Posted February 19, 2009 Share Posted February 19, 2009 Maybe we need to have another look at the server or your network setup. Don't worry about it. We'll figure this out. I still would like to know what you're going to use this for. It is not often that a client connects to multiple servers. github.com/jvanegmond Link to comment Share on other sites More sharing options...
JohnRichard Posted February 19, 2009 Author Share Posted February 19, 2009 Maybe we need to have another look at the server or your network setup. Don't worry about it. We'll figure this out.I still would like to know what you're going to use this for. It is not often that a client connects to multiple servers.i'm back manadar. yes i've searched in the forum but failed to get sample that client connects to multiple servers as with my case.basically i will use this for simple support for client computers in LAN. basically maybe 30 or more PC's in LAN will communicate in 3 servers that mostly are online.what i wanted to happen, 3 tcp servers which will host by 3 support users will try to accept any incoming connection on client PC's. this is per request. like when user got PC problem, as in the client script, there is a hotkey in which when user on client PC press the hotkey, client will notify the host servers that a client successfully connects either means by traytip or a message box. in such a case that client PC could not connect to one server, it will then look for another online server and post the connection. after successful connection, it will post the message who ever TCP server is online. also i have a GUI which when user pressed the hotkey, the GUI will pop up on the user's PC with some INFOlike IP Address. This GUI, i would like also to pop up on the online servers.That info will then be used by the support on the host server to connect to the PC by any remote control program.is my idea will be good enough to have this setup a finished project? hope this will enlighten you of what i want to picture. i will be forever grateful if sooner you guys will help me.thank you. Link to comment Share on other sites More sharing options...
jvanegmond Posted February 19, 2009 Share Posted February 19, 2009 Based on your story, I would say that a set up like this is much simpler and can be easily expanded on.Clients connect to a main server and post a request for help. Administrator software looks on the main server for requests for help and based on that a connection to the client can be made.Just one of the benefits of this is that the clients do not need to know administrator IP addresses, and administrators do not need to know client IP addresses. Just one address needs to be static, which is of the main server. github.com/jvanegmond Link to comment Share on other sites More sharing options...
JohnRichard Posted February 19, 2009 Author Share Posted February 19, 2009 Based on your story, I would say that a set up like this is much simpler and can be easily expanded on.Clients connect to a main server and post a request for help. Administrator software looks on the main server for requests for help and based on that a connection to the client can be made.Just one of the benefits of this is that the clients do not need to know administrator IP addresses, and administrators do not need to know client IP addresses. Just one address needs to be static, which is of the main server.hello manadar. the diagram you showed me is nice to setup. if that is so, how will the script will apply to that? so how would then the administrator will receive for any client requests?in my case, i just wanted that 3 computers will be hosting a TCP server which will listen for any client connection. as for the server will not be used to store any data. it will just receive any client as per request. i just wanted that when a successful client connects, these 3 TCP servers will get notified. its just a server/client communication and there is no picture or text file involved.is my setup not possible? please i need your expertise on this.appreciate if you can make clients connects to these 3 servers simultaneously. i'm running out of my mind how will it work. Link to comment Share on other sites More sharing options...
JohnRichard Posted February 19, 2009 Author Share Posted February 19, 2009 hope someone in this forum, will try to look and see what's worng with script why it doesn't connect. CLIENT CODE HotKeySet("{PAUSE}","SendCom") Global $SERVER[3] = ["192.168.0.1","192.168.0.2","192.168.0.3"] Global $PORT = 1255 TCPStartup() $CLIENT = TCPConnect($SERVER[1], $PORT) If @error Then MsgBox(0,"ERROR","Error to connect to server") Else MsgBox(0,"Connected","Connected to server" & $SERVER[1]) EndIf While 1 $RECV = TCPRecv($CLIENT,512) If @error Then MsgBox(0,"ERROR","Disconnected to server") Else $CLIENT = TCPConnect($SERVER[2], $PORT) TCPSend($CLIENT, "Connected to" & $SERVER[2]) If @error Then MsgBox(0,"ERROR","Error to connect to server") Else $CLIENT = TCPConnect($SERVER[3], $PORT) TCPSend($CLIENT, "Connected to" & $SERVER[3]) EndIf EndIf If $RECV <> "" Then MsgBox(0,"Message",$RECV) EndIf Sleep(20) WEnd Func SendCom() TCPSend($CLIENT, "Message") EndFunc Link to comment Share on other sites More sharing options...
Andreik Posted February 19, 2009 Share Posted February 19, 2009 No offense, but nobody understand what you want to do. If is too hard for you to understand how work this things maybe you should learn more and then you'll can do what you want. When the words fail... music speaks. Link to comment Share on other sites More sharing options...
jvanegmond Posted February 19, 2009 Share Posted February 19, 2009 John, your client code is fine. You may stop posting it. Please allow me ( up to ) 36 hours to write some code that will work and is easy to use. github.com/jvanegmond Link to comment Share on other sites More sharing options...
JohnRichard Posted February 20, 2009 Author Share Posted February 20, 2009 John, your client code is fine. You may stop posting it.Please allow me ( up to ) 36 hours to write some code that will work and is easy to use.thanks manadar. i'll be waiting for your next response. i'll try also to look for other examples on this forum so that i can have a better understanding working more on AutoIt script. Link to comment Share on other sites More sharing options...
jvanegmond Posted February 20, 2009 Share Posted February 20, 2009 (edited) thanks manadar. i'll be waiting for your next response. i'll try also to look for other examples on this forum so that i can have a better understanding working more on AutoIt script.Sure. In the meanwhile I can recommend these:http://www.autoitscript.com/forum/index.php?showtopic=20589http://www.autoitscript.com/forum/index.php?showtopic=18738themax90 (formerly AutoItSmith) pretty much taught me the basics of TCP and how to use them in AutoIt. It is a really good introduction to communication between computers in general as well. Edited February 20, 2009 by Manadar github.com/jvanegmond Link to comment Share on other sites More sharing options...
JohnRichard Posted February 20, 2009 Author Share Posted February 20, 2009 Sure. In the meanwhile I can recommend these:http://www.autoitscript.com/forum/index.php?showtopic=20589http://www.autoitscript.com/forum/index.php?showtopic=18738themax90 (formerly AutoItSmith) pretty much taught me the basics of TCP and how to use them in AutoIt. It is a really good introduction to communication between computers in general as well.is that so? yeah i have read TCP samples from the max90 but for me i can't understand it the way you do coz i'm totally newbie and starting to learn. maybe in the future i'll be good like you and others do.i'll have a look on the url's you posted while waiting for your script. surely it will be interesting to see the the script completed by you. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now