Delphi Xe2 Socket Error 10061
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the asynchronous socket error 10061 delphi company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions socket error 10061 connection refused delphi Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Socket Error while making tcp ip connection in delphi up vote 2 down vote favorite I am using indy client to make tcp ip connection with a server(IP address and port). I have written following code on the click of a button. I trying to send Hello msg to server and then trying to read the message from server. procedure TForm1.Button1Click(Sender: TObject); var sMsg : string; begin try IdTCPClient1.Port := xxxx; //Set port to connect to IdTCPClient1.Host := 'xxx.xxx.x.xxxx'; //Set host to connect to IdTCPClient1.Connect; //Make connection sMsg := IdTCPClient1.Socket.ReadLn; //Read the response from the server ShowMessage(sMsg); except on E : Exception do begin ShowMessage('Connection Error: ' + E.Message); exit; end; end; end; But I am getting socket error 10061 connection refused while debugging at the line IdTCPClient1.Connect; //Make connection I tried to make tcp connection with server on given port and ip using telnet command on cmd (telnet ip port) and I got the following message "Connection established to xxx.xxx.xx.xxx, there could be no connection made with the host, on port xxxx: connection errors" Please suggest me the solution for this... Thanks all. Now I am able to use the port. So no error at IdTCPClient1.Connect; //Make connection. But now nothing is happening at the next line where I am trying to read data from the server (sMsg := IdTCPClient1.Socket.ReadLn;) When I try from telnet, some miscellaneous characters are read from server. What could be the reason for this? delphi sockets networking tcp delphi-xe2 share|improve this question edited Nov 20 '12 at 7:19 asked Nov 19 '12 at 5:57 user1556433 2 Is there actually a program running on the server that listens to the specific port? Also, have you checked that there is no firewall stopping you? –Joachim Pileborg Nov 19 '12 at 8:47 I have ensured that program is running on server that listens to t
Lines ... Andrzej Brzezinski wrote on 23-Nov-2012: I cannot get it a datasnap application to work when a server app is installed on another Windows computer. It works fine on the when both client and server run on the same system. I have opened the port I am using in the Firewall on both computers. 11 ... Bob Swart replied on 24-Nov-2012: Hi Andrzej, (snip) Which protocol are you using? When using HTTPS, are http://stackoverflow.com/questions/13448429/socket-error-while-making-tcp-ip-connection-in-delphi you also deploying the SSL DLLs? Can you ping from one computer to another? Did you start the DataSnap Server on the other windows machine? (just 53 ... Andrzej Brzezinski replied on 24-Nov-2012: Hi Bob, Your message got me on the right track - I was setting Params dynamically and I used http://www.codenewsfast.com/cnf/thread/0/permalink.thr-ng1933q1434 'Host' instead of 'HostName'. But now, I am getting a different error : "Socket error 10060, connection timeout.' 16 ... Andrzej Brzezinski replied on 26-Nov-2012: It took me a while to find out that Filters on the client must be listed in reverse order compared to Filters on the server. Finally, everything seems to work now. Thank you, 7 ... Bob Swart replied on 26-Nov-2012: Hi Andrzej, (snip) Actually, if you do not specify the filters at all, they will be used automatically (and in the right order). Just make sure the units that define (and register) the filters are included in the uses clause somewhere in the client application... 43 FYI: Phrase searches are enclosed in either single or double quotes 24-Jul 11:00 utc Operating system upgrade in process, expect some down time. Originally created by [Tamarack] Sun, 09 Oct 2016 01:02:45 UTC Copyright © 2009-2016 HREF Tools Corp.
Reply to this Thread Search Forum Back to Thread List Replies: 3 - Last Post: Jun 15, 2015 8:34 AM Last Post By: Michael Eriksen Michael Eriksen Posts: 14 Registered: 6/29/15 Datasnap and connecting from app to a server - 10061 connection https://forums.embarcadero.com/message.jspa?messageID=702046 refused Reply Posted: May 29, 2015 7:17 AM rest , server , datasnap , firedac , mobile , xe8 Hey all, I wuld be glad if someone can help me. I have now created a client/server solution for an App using Delphi XE8 on Windows 7. But all the time I get the error 10061 connection refused. I have checked my public IP address, that the server is running, and checked that the server shouldn't socket error be busy. I also have tried to deactivate my firewall and antivirus with no success. So I don't know where to look for finding the problem with the connection from app to server. I really hope that someone can give some ideas. best regards Michael Edited by: Michael Eriksen on Jun 1, 2015 2:57 AM Hikaru FUKUSHI Posts: 43 Registered: 11/11/02 Re: Datasnap and connecting from app to a server - 10061 connection refused Reply socket error 10061 Posted: Jun 1, 2015 4:01 AM in response to: Michael Eriksen Hi, Michael Michael Eriksen wrote: I have now created a client/server solution for an App using Delphi XE8. But all the time I get the error 10061 connection refused. Is datamodule "ServerContainerUnit1" created? If you checked off "auto create" on IDE option, the server containter datamodule must be create "manualy". See here: http://stackoverflow.com/questions/22678393/datasnap-server-socket-error-10061 -- Hikaru Fukushi Michael Eriksen Posts: 14 Registered: 6/29/15 Re: Datasnap and connecting from app to a server - 10061 connection refused Reply Posted: Jun 1, 2015 4:59 AM in response to: Hikaru FUKUSHI android , delphi_xe8 , firemonkey , mobile , xe8 , datasnap Is datamodule "ServerContainerUnit1" created? If you checked off "auto create" on IDE option, the server containter datamodule must be create "manualy". See here: http://stackoverflow.com/questions/22678393/datasnap-server-socket-error-10061 -- Hikaru Fukushi Thanks for your reply. Yes, it has been created - but still the same error Any ideas?? Edited by: Michael Eriksen on Jun 4, 2015 3:19 AM Michael Eriksen Posts: 14 Registered: 6/29/15 Re: Datasnap and connecting from app to a server - 10061 connection refused Reply Posted: Jun 15, 2015 8:34 AM in response to: Michael Eriksen Yes, it has been created - but still the same error Any ideas?? My problem is that I have confused my environment, so my application could'