|
-
Feb 3rd, 2004, 03:00 PM
#1
Thread Starter
Addicted Member
Get Window Class ?
... I need the backwards of FindWindow... I have the hwnd of a window and I want to know the window's class name... is there such a function?
- Visual Basic 6.0
- Windows XP Home
-
Feb 3rd, 2004, 03:01 PM
#2
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
-
Feb 3rd, 2004, 03:03 PM
#3
More to the point...
VB Code:
Private Declare Function GetClassName Lib "user32" Alias "GetClassNameA" (ByVal hwnd As Long, _
ByVal lpClassName As String, _
ByVal nMaxCount As Long) _
As Long
Private Sub Command1_Click()
Dim s As String
s = Space$(255)
Call GetClassName(Command1.hwnd, s, Len(s))
If InStr(1, s, vbNullChar) Then
s = Left$(s, InStr(1, s, vbNullChar) - 1)
End If
MsgBox s
End Sub
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
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
|