Im having trouble with my internet linking. I have a picture boc named picq that i want the user to be able to click to take them to a web page.
i tried the following:
picq.picture =(url)
im new to this so bear with me
Im having trouble with my internet linking. I have a picture boc named picq that i want the user to be able to click to take them to a web page.
i tried the following:
picq.picture =(url)
im new to this so bear with me
At the very top of your form:
Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long
Then in your picturebox_click:
shellexecute me.hwnd, "open", cstr(url), "c:\", 1
this didnt work.
My Bad, I forgot a Parameter:
Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long
Private Sub Form_Load()
url = "http://www.hotmail.com"
ShellExecute Me.hwnd, "open", CStr(url), "", "c:\", 1
End Sub
ive tried it but still nothing. As soon as i put the code onm line one on my form it guves me an error
Are you using VB 4, 5, or 6?
And if you are copying and pasting you are removing the line numbers?
What is the error message?
never mind now, it works. Thanks so much.
I had had to chance line 3 of your code tho to:
Private Sub Picture1_Click()
Its vb6 im using. Im very new to this as part of my assignment but I will definitly fully reference the code and source and make sure I understand it
thanks again
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.