vb.net - IsWindow returns false for existing window handle -
in vb6 application checking if vb.net winforms window exists:
public declare function iswindow lib "user32" (byval hwnd long) long if not iswindow(102937) messagebox("window not found!") end if the messagebox shown, window exist.
i inspect
debug.print(me.handle.toint32)'it prints 102937 what goes wrong here? perhaps handling return value of "iswindow" incorrectly?
thank you.
i found solution:
i indeed using winapi function incorrectly.
i should have used
if iswindow(102937) <> 1
Comments
Post a Comment