Option Explicit On
Public Class Form1
Inherits System.Windows.Forms.Form
Public 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
Public Const SW_NORMAL = 1
Public Sub PictureBox1_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles PictureBox1.Click
ShellExecute(Me.hWnd, String, " vbNullString, "C:\", SW_NORMAL)
End Sub
********************************
but i get an error saying hWnd not a member of winapp.Form1
any clues as to why i get this error?
i mean all i want to do, is to create a simple form, put an img in it, then when someone clicks on the image, it opens a web browser and goes to a certain page.
can someone plz help. i have restarted this application like 5 times and i am not successful.
Public Class Form1
Inherits System.Windows.Forms.Form
Public 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
Public Const SW_NORMAL = 1
Public Sub PictureBox1_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles PictureBox1.Click
ShellExecute(Me.hWnd, String, " vbNullString, "C:\", SW_NORMAL)
End Sub
********************************
but i get an error saying hWnd not a member of winapp.Form1
any clues as to why i get this error?
i mean all i want to do, is to create a simple form, put an img in it, then when someone clicks on the image, it opens a web browser and goes to a certain page.
can someone plz help. i have restarted this application like 5 times and i am not successful.