Register | Login | |||||
Main
| Memberlist
| Active users
| Calendar
| Chat
| Online users Ranks | FAQ | ACS | Stats | Color Chart | Search | Photo album |
| |
0 users currently in Programming. |
Acmlm's Board - I3 Archive - Programming - GetWindowModuleFileName just doesn't work | New poll | | |
Add to favorites | Next newer thread | Next older thread |
User | Post | ||
HyperHacker Star Mario Finally being paid to code in VB! If only I still enjoyed that. <_< Wii #7182 6487 4198 1828 Since: 11-18-05 From: Canada, w00t! My computer's specs, if anyone gives a damn. STOP TRUNCATING THIS >8^( Last post: 6431 days Last view: 6431 days |
| ||
I can't seem to figure out why but for some reason, GetWindowModuleFileName() just doesn't seem to work. I pass it one window's handle, and it returns the module of another or nothing at all. The desktop window returns shell32.dll which is correct, but the taskbar, created by the same process, returns nothing. Notepad and Calculator return nothing, and Winamp and Console (command prompt frontend) return the name of the program calling it! | |||
Vertex Newcomer Since: 01-08-06 From: Philippines Last post: 6836 days Last view: 6836 days |
| ||
Are you absolutely sure that you are providing a valid hWnd? And if you're using the unicode version of GWMFN() then are you sure it's not returning a unicode string and your program is trying to interpret it as ANSI? | |||
HyperHacker Star Mario Finally being paid to code in VB! If only I still enjoyed that. <_< Wii #7182 6487 4198 1828 Since: 11-18-05 From: Canada, w00t! My computer's specs, if anyone gives a damn. STOP TRUNCATING THIS >8^( Last post: 6431 days Last view: 6431 days |
| ||
It has to be valid, because passing the same hWnd to other functions gives correct results, and it's not the Unicode version. The function actually returns 0, as in 0 characters copied, or returns the name of the program that called it. | |||
Vertex Newcomer Since: 01-08-06 From: Philippines Last post: 6836 days Last view: 6836 days |
| ||
Could you post the code you are using to get the hWnd and process module filename? | |||
HyperHacker Star Mario Finally being paid to code in VB! If only I still enjoyed that. <_< Wii #7182 6487 4198 1828 Since: 11-18-05 From: Canada, w00t! My computer's specs, if anyone gives a damn. STOP TRUNCATING THIS >8^( Last post: 6431 days Last view: 6431 days |
| ||
Don't see why not.
CurrentWindow.hWnd = GetForegroundWindow();
|
Add to favorites | Next newer thread | Next older thread |
Acmlm's Board - I3 Archive - Programming - GetWindowModuleFileName just doesn't work | | |