|
-
Oct 29th, 2009, 02:46 PM
#1
Thread Starter
New Member
external ip adres - microsoft internet transfer control 6.0?
hello all
i'm making a program, wich has to show the external ip-adress.
i google'd alot for it, and i got a solution:
Code:
create a form
add a label, command box, and the Microsoft Internet Transfer Control 6.0
Then add this code
Option Explicit
Private Sub Command1_Click()
Dim Data As String
Data = Inet1.OpenURL("http://www.showmyip.com/simple/")
If Not Inet1.StillExecuting Then
Label1.Caption = Left(Data, InStr(Data, " ") - 1)
End If
End Sub
http://www.experts-exchange.com/Programming/Languages/Visual_Basic/Q_20932248.html
But the problem is, i don't know what the "Microsoft Internet Transfer Control" is, how i can use it and where i can find it. Could anyone explain me in simple steps how i have to use this, and maybe, how i can get above code working
thank u very much
-koffiedik
-
Oct 29th, 2009, 04:11 PM
#2
Re: external ip adres - microsoft internet transfer control 6.0?
Go to Project -> Components and select "Microsoft Internet Transfer Control 6.0" from the list and click OK. On the left side of the main screen a new control appears. Add it to the form.
Add a Command button and a Label to the form. Then add the following code, because "http://www.showmyip.com/simple/" doesn't work anymore.
Code:
Private Sub Command1_Click()
Dim Data As String
Data = Inet1.OpenURL("http://www.whatismyip.com/automation/n09230945.asp")
If Not Inet1.StillExecuting Then
Label1.Caption = Trim$(Data)
End If
End Sub
-
Oct 30th, 2009, 04:49 AM
#3
Thread Starter
New Member
Re: external ip adres - microsoft internet transfer control 6.0?
ok thanks, but if i select
the MS internet control the program crashes.
i tried to google it, but i couldnt find any solution.
does anyone know this problem, and/or the solution?
-edit
i solved the crashed thingy
it seemed that the school administrator blocked some of those files that were needed -.-
at my home it just worked fine =D
thank you very much =D
Last edited by koffiedik; Oct 30th, 2009 at 11:19 AM.
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
|