Sign in to follow this  
Followers 0
eEniquEe

Can TCPConnect connect 2 computers from afar?

15 posts in this topic

Hi everyone,

I'm really banging my head over the wall now.. ;)( I have one script serving as the Server, and the other one as the Client.

When I run 2 scripts in one computers, it works fine. But if I run it on 2 distinct computers, the Client just cannot Connect to the Server, although I did try to use the Server's Real IP Address. :idiot: I don't really know what happens. :idiot:

Huhuhu.. What should I do now.. :D( Is it that TCPConnect can only work inside LAN network? Or is it me doing something wrong.. :D(

Thanks guys a lot,

And have a good day, :)

Share this post


Link to post
Share on other sites



I'm connecting from my own computer to my neighbor's one. And no, I don't use any Firewall.

On doing some searching on Google, I think I should first do something like Port Forward, and stuff like that, right? Should I create a static IP address as well? ;) I'm sorry if I sound too inexperienced, I'm new on these stuff. :idiot:

Thanks a lot in advance, :)

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

I'm connecting from my own computer to my neighbor's one. And no, I don't use any Firewall.

Your neighbour as in the same room on the same LAN or next House? Edited by Jos

Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

Plus, correct me if I am wrong but if you have to use "Port Forwarding" then surely there is a "Router" with the Firewall enabled. For the Server you would have to have a Static IP so the client wouldn't have to change the IP every time DHCP (Router) assigns a new IP to the Server.


_AdapterConnections()_AlwaysRun()_AppMon()_AppMonEx()_BinaryBin()_CheckMsgBox()_CmdLineRaw()_ContextMenu()_ConvertLHWebColor()/_ConvertSHWebColor()_DesktopDimensions()_DisplayPassword()_DotNet_Load()/_DotNet_Unload()_Fibonacci()_FileCompare()_FileCompareContents()_FileNameByHandle()_FilePrefix/SRE()_FindInFile()_GetBackgroundColor()/_SetBackgroundColor()_GetConrolID()_GetCtrlClass()_GetDirectoryFormat()_GetDriveMediaType()_GetFilename()/_GetFilenameExt()_GetHardwareID()_GetIP()_GetIP_Country()_GetOSLanguage()_GetSavedSource()_GetStringSize()_GetSystemPaths()_GetURLImage()_GIFImage()_GoogleWeather()_GUICtrlCreateGroup()_GUICtrlListBox_CreateArray()_GUICtrlListView_CreateArray()_GUICtrlListView_SaveCSV()_GUICtrlListView_SaveHTML()_GUICtrlListView_SaveTxt()_GUICtrlListView_SaveXML()_GUICtrlMenu_Recent()_GUICtrlMenu_SetItemImage()_GUICtrlTreeView_CreateArray()_GUIDisable()_GUIImageList_SetIconFromHandle()_GUIRegisterMsg()_GUISetIcon()_Icon_Clear()/_Icon_Set()_IdleTime()_InetGet()_InetGetGUI()_InetGetProgress()_IPDetails()_IsFileOlder()_IsGUID()_IsHex()_IsPalindrome()_IsRegKey()_IsStringRegExp()_IsSystemDrive()_IsUPX()_IsValidType()_IsWebColor()_Language()_Log()_MicrosoftInternetConnectivity()_MSDNDataType()_PathFull/GetRelative/Split()_PathSplitEx()_PrintFromArray()_ProgressSetMarquee()_ReDim()_RockPaperScissors()/_RockPaperScissorsLizardSpock()_ScrollingCredits_SelfDelete()_SelfRename()_SelfUpdate()_SendTo()_ShellAll()_ShellFile()_ShellFolder()_SingletonHWID()_SingletonPID()_Startup()_StringCompact()_StringIsValid()_StringRegExpMetaCharacters()_StringReplaceWholeWord()_StringStripChars()_Temperature()_TrialPeriod()_UKToUSDate()/_USToUKDate()_WinAPI_Create_CTL_CODE()_WinAPI_CreateGUID()_WMIDateStringToDate()/_DateToWMIDateString()Au3 script parsingAutoIt SearchAutoIt3 PortableAutoIt3WrapperToPragmaAutoItWinGetTitle()/AutoItWinSetTitle()CodingDirToHTML5FileInstallrFileReadLastChars()GeoIP databaseGUI - Only Close ButtonGUI ExamplesGUICtrlDeleteImage()GUICtrlGetBkColor()GUICtrlGetStyle()GUIEventsGUIGetBkColor()Int_Parse() & Int_TryParse()IsISBN()LockFile()Mapping CtrlIDsOOP in AutoItParseHeadersToSciTE()PasswordValidPasteBinPosts Per DayPreExpandProtect GlobalsQueue()Resource UpdateResourcesExSciTE JumpSettings INISHELLHOOKShunting-YardSignature CreatorStack()Stopwatch()StringAddLF()/StringStripLF()StringEOLToCRLF()VSCROLLWM_COPYDATAMore Examples...

Updated: 04/09/2015

Share this post


Link to post
Share on other sites

He's next house. ;)

I did test with 2 computer in the same LAN, and it seems to work perfectly. I think the problem stemps from the fact that we are communicating from 2 different external addresses. So I need to do the Port Forwarding stuff, am I on the right track?

Thanks a lot, :)

Share this post


Link to post
Share on other sites

Plus, correct me if I am wrong but if you have to use "Port Forwarding" then surely there is a "Router" with the Firewall enabled. For the Server you would have to have a Static IP so the client wouldn't have to change the IP every time DHCP (Router) assigns a new IP to the Server.

Could this can be solved by putting a file on the Internet, consisting my external address every time I reset the modem? And the Client can just read the file from the net?

Share this post


Link to post
Share on other sites

I would say (don't really use AutoIt for TCP/IP) "Forward a Port" on their Router to the LAN IP Address they are using and either look at getting a Static IP Address from your (both you and your neighbour's) ISP or look at http://www.dyndns.com/ and enabling on both Routers.

Depending on what you are doing I would have just created a VPN using Hamachi or for non-commercial purposes TeamViewer.


_AdapterConnections()_AlwaysRun()_AppMon()_AppMonEx()_BinaryBin()_CheckMsgBox()_CmdLineRaw()_ContextMenu()_ConvertLHWebColor()/_ConvertSHWebColor()_DesktopDimensions()_DisplayPassword()_DotNet_Load()/_DotNet_Unload()_Fibonacci()_FileCompare()_FileCompareContents()_FileNameByHandle()_FilePrefix/SRE()_FindInFile()_GetBackgroundColor()/_SetBackgroundColor()_GetConrolID()_GetCtrlClass()_GetDirectoryFormat()_GetDriveMediaType()_GetFilename()/_GetFilenameExt()_GetHardwareID()_GetIP()_GetIP_Country()_GetOSLanguage()_GetSavedSource()_GetStringSize()_GetSystemPaths()_GetURLImage()_GIFImage()_GoogleWeather()_GUICtrlCreateGroup()_GUICtrlListBox_CreateArray()_GUICtrlListView_CreateArray()_GUICtrlListView_SaveCSV()_GUICtrlListView_SaveHTML()_GUICtrlListView_SaveTxt()_GUICtrlListView_SaveXML()_GUICtrlMenu_Recent()_GUICtrlMenu_SetItemImage()_GUICtrlTreeView_CreateArray()_GUIDisable()_GUIImageList_SetIconFromHandle()_GUIRegisterMsg()_GUISetIcon()_Icon_Clear()/_Icon_Set()_IdleTime()_InetGet()_InetGetGUI()_InetGetProgress()_IPDetails()_IsFileOlder()_IsGUID()_IsHex()_IsPalindrome()_IsRegKey()_IsStringRegExp()_IsSystemDrive()_IsUPX()_IsValidType()_IsWebColor()_Language()_Log()_MicrosoftInternetConnectivity()_MSDNDataType()_PathFull/GetRelative/Split()_PathSplitEx()_PrintFromArray()_ProgressSetMarquee()_ReDim()_RockPaperScissors()/_RockPaperScissorsLizardSpock()_ScrollingCredits_SelfDelete()_SelfRename()_SelfUpdate()_SendTo()_ShellAll()_ShellFile()_ShellFolder()_SingletonHWID()_SingletonPID()_Startup()_StringCompact()_StringIsValid()_StringRegExpMetaCharacters()_StringReplaceWholeWord()_StringStripChars()_Temperature()_TrialPeriod()_UKToUSDate()/_USToUKDate()_WinAPI_Create_CTL_CODE()_WinAPI_CreateGUID()_WMIDateStringToDate()/_DateToWMIDateString()Au3 script parsingAutoIt SearchAutoIt3 PortableAutoIt3WrapperToPragmaAutoItWinGetTitle()/AutoItWinSetTitle()CodingDirToHTML5FileInstallrFileReadLastChars()GeoIP databaseGUI - Only Close ButtonGUI ExamplesGUICtrlDeleteImage()GUICtrlGetBkColor()GUICtrlGetStyle()GUIEventsGUIGetBkColor()Int_Parse() & Int_TryParse()IsISBN()LockFile()Mapping CtrlIDsOOP in AutoItParseHeadersToSciTE()PasswordValidPasteBinPosts Per DayPreExpandProtect GlobalsQueue()Resource UpdateResourcesExSciTE JumpSettings INISHELLHOOKShunting-YardSignature CreatorStack()Stopwatch()StringAddLF()/StringStripLF()StringEOLToCRLF()VSCROLLWM_COPYDATAMore Examples...

Updated: 04/09/2015

Share this post


Link to post
Share on other sites

#9 ·  Posted (edited)

He's next house. ;)

I did test with 2 computer in the same LAN, and it seems to work perfectly. I think the problem stemps from the fact that we are communicating from 2 different external addresses. So I need to do the Port Forwarding stuff, am I on the right track?

Thanks a lot, :)

So, are you connecting to your neighbours public IP address and do you have port forwarding enabled for the port you connect to (assuming the Server site is your Neighbour?

Jos

Edited by Jos

Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

#10 ·  Posted (edited)

I would say (don't really use AutoIt for TCP/IP) "Forward a Port" on their Router to the LAN IP Address they are using and either look at getting a Static IP Address from your (both you and your neighbour's) ISP or look at http://www.dyndns.com/ and enabling on both Routers.

Depending on what you are doing I would have just created a VPN using Hamachi or for non-commercial purposes TeamViewer.

I'm sorry, but what's VPN, and Hamachi? :idiot:

So, are you connecting to your neighbours public IP address and do you have port forwarding enabled for the port you connect to (assuming the Server site is your Neighbour?

Jos

The Server site is my computer. I did spend all day trying to:

  • Create a static Internal IP Address (I think I did manage to do it, my internal IPAddress is 192.168.0.125).

    Posted Image

  • Enabling Port Forwarding (Port 61635).

    Posted Image

I do everything they guide on the Net, but it still doesn't work out for some strange reasons. :);):idiot:

Posted Image

What should I do now? I'm using wireless connection:

My ADSL Router is DSL-5526B.

And my Wireless Router is DIR-300.

Did I do something wrong? :D

Edited by eEniquEe

Share this post


Link to post
Share on other sites

#11 ·  Posted (edited)

Well, did you click that "Save Settings" button on second pic?

And maybe your TCPConnect script is broken. Show it maybe.

edit:

I just did port forwarding on port 80 for my machine for practice and all works fine. My current IP address is 83.131.86.253.

That means you should be able to access my comp in your browser by typing or clicking http://83.131.86.253/

Edited by trancexx

♡♡♡

.

eMyvnE

Share this post


Link to post
Share on other sites

Well, did you click that "Save Settings" button on second pic?

And maybe your TCPConnect script is broken. Show it maybe.

edit:

I just did port forwarding on port 80 for my machine for practice and all works fine. My current IP address is 83.131.86.253.

That means you should be able to access my comp in your browser by typing or clicking http://83.131.86.253/

Yes, I did click on that Save Settings button.

When connecting to my own External IP Address: http://116.118.32.243/ it prompts for Username, and Password. :-? Does that mean that I'm standing behind the Firewall or something along the line? @.@

Share this post


Link to post
Share on other sites

Probably credentials for router.

Thing is when I click your link it says page is not available. That probably means you aren't port forwarding. At least not on port 80, that is.

Was my IP working for you?


♡♡♡

.

eMyvnE

Share this post


Link to post
Share on other sites

#14 ·  Posted (edited)

Probably credentials for router.

Thing is when I click your link it says page is not available. That probably means you aren't port forwarding. At least not on port 80, that is.

Was my IP working for you?

Yes, it did in like 15 minutes ago. But now it doesn't.

I think I gotta do some more searching. ;) I did port forward some years ago on a wired connection, and it did work. But why can't I do it on wireless connection. :idiot: This is driving me insane. :)

Edited by eEniquEe

Share this post


Link to post
Share on other sites

I've changed my IP.

And also I have wireless connection.

Good luck!


♡♡♡

.

eMyvnE

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0