FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Can I change my IP address with Fivewin/Harbour?
Posts: 57
Joined: Sun Apr 12, 2009 10:51 AM
Can I change my IP address with Fivewin/Harbour?
Posted: Sat Jul 16, 2016 03:07 AM

Dear Members,

Can I change my IP address with FiveWin/Harbours?

I am using Internet by ISP company.

If possible, please let me have some sample or link on IP Change.

Thanks.

Posts: 1335
Joined: Fri Jun 13, 2008 11:04 AM
Re: Can I change my IP address with Fivewin/Harbour?
Posted: Sat Jul 16, 2016 04:07 AM
Code (fw): Select all Collapse
cAdapterType:="Local Area Connection"
cIP:="192.168.0.200"
cSubNet:="255.255.255.0"
cGateWay:="192.168.0.1"

oShell = CreateObject("Wscript.Shell")
oShell:Run ( 'netsh interface ipv4 set address name="'+cAdapterType+'" source=static address='+cIP+' mask='+cSubNet+' gateway='+cGateWay,0,.T. )
oShell:Run ( 'netsh interface ipv4 set dns name = "'+cAdapterType+'" source = static addr ='+cDns1,0,.T. )


Regards

Anser
Posts: 57
Joined: Sun Apr 12, 2009 10:51 AM
Re: Can I change my IP address with Fivewin/Harbour?
Posted: Sat Jul 23, 2016 02:06 AM

Thanks so much Mr.anserkk!

I was in business travel, and found your answer today...

Continue the discussion