|
-
October 23rd, 2010, 12:47 AM
#1
Findwindow/FindwindowEX on VMWare program in VB6
Hey all, i am trying to grab some text input from notepad thats within a VMWare virtual machine running Windows 7. I can get a handle of the VMWare form but nothing within it (the windows 7 OS running inside it).
This is the code i am currently using:
Code:
Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Private Declare Function FindWindowEx Lib "user32" Alias "FindWindowExA" (ByVal hWnd1 As Long, ByVal hWnd2 As Long, ByVal lpsz1 As String, ByVal lpsz2 As String) As Long
Private Sub Commandcc_Click()
Dim FromHwnd As Long
Dim hWin As Long
Dim count As Integer
FromHwnd = FindWindow("VMUIFrame", vbNullString)
hWin = FindWindowEx(FromHwnd, 0&, "MKSEmbedded", "")
End Sub
I am getting a value for FromHwnd just fine, but once it goes into the EX, i get no value. The **MKSEmbedded** is the window inside the VMWare that Windows 7 is running in.
Is there something i am missing or need to do in order to grab that window inside VMWare?
Thanks!
David
-
October 23rd, 2010, 01:12 AM
#2
Re: Findwindow/FindwindowEX on VMWare program in VB6
That isn't a standard error key. Check their support page
-
October 23rd, 2010, 09:21 AM
#3
Re: Findwindow/FindwindowEX on VMWare program in VB6
If I understand correctly what you are trying to do, there is little chance that you will get that to work. The host OS that both your app and VMWare run on doesn't know anything about what's going on inside the VM. Your best bet could be that VMWare would provide some API that allows to access VM internals, but I'm afraid something like that doesn't exist either or it wouldn't be able to do what you want.
Sorry.
Last edited by Eri523; October 23rd, 2010 at 08:54 PM.
I was thrown out of college for cheating on the metaphysics exam; I looked into the soul of the boy sitting next to me.
This is a snakeskin jacket! And for me it's a symbol of my individuality, and my belief... in personal freedom.
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
|