On what basis are you using globs ("*lient*", etc) in FindWindow? If I 
understand correctly, the w32 and w32a packages are just wrapping Windows 
APIs, so the semantics of the use should match the equivalent use of the 
windows API. The documentation for FindWindow says "Retrieves a handle to 
the top-level window whose class name and window name match the specified 
strings." - that does not appear to me to be implying that it supports 
globbing.

See this relevant question on 
StackOverflow: 
https://stackoverflow.com/questions/16530871/findwindow-does-not-find-the-a-window

You might find the EnumWindows function more useful, as you can loop over 
the returned windows, and use GetClassName and GetWindowText to get some 
text you can then compare against.

https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-enumwindows
 

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/cac11ef5-4890-41e7-9e6b-08960c32728cn%40googlegroups.com.

Reply via email to