Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

hWnd not a member of?

Status
Not open for further replies.

bobo12

Programmer
Dec 26, 2004
74
US
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.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top