|
-
Oct 8th, 2001, 01:20 AM
#1
Thread Starter
Hyperactive Member
server's IP ( static )
I made a client/server app and it works perfectly but the server's IP (my machine's IP) differs from time to time also the client side may not connect to the server side if i am not connected to the internet.
I am not affined by the Internet always.
Is it possible to consider a webpage as a server?
any idea??
-
Oct 8th, 2001, 04:56 AM
#2
If you have a broadband connection I would simply force my dynamic ip address to be static. Another option would be to use a service like dynip or some other ip forwarding service.
-
Oct 8th, 2001, 06:20 AM
#3
I've been working on a little something that downloads in IP from a webpage. The page is updated by the person running the server and the clients download the data on that page connect using the IP on that page.
-
Oct 8th, 2001, 01:02 PM
#4
Thread Starter
Hyperactive Member
could anyone give me a small example for that
-
Oct 8th, 2001, 02:08 PM
#5
This is a way to do it:
VB Code:
'Put that in the form load or in a button
DownloadFile "http://mywebpage.com/ip.txt", "C:\ip.txt"
Open "C:\ip.txt" For Input As #1
myIp = Input(LOF(1), 1)
Close #1
'This is the Function
Private Function DownloadFile(URL As String, _
LocalFilename As String) As Boolean
Dim lngRetVal As Long
lngRetVal = URLDownloadToFile(0, URL, LocalFilename, 0, 0)
If lngRetVal = 0 Then DownloadFile = True
End Function
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|