help! How to test visibility of windows of unscriptable application

Hi, I am new to applescript.

I am trying to use “systemevents” to test visibility of windows of an unscriptable application process.

tell app “SystemEvents”
tell application process “b”
tell window “a”
get visible of it
end
end
end

I constantly get errors that says coercion impossible for visibile into type reference. I used script debugger to trace and it does show me that visible property is not there because of conversion error but according to the documenation of “system events”, this is a very common property of a window.

Can somebody tell me what i did wrong. i know that if the application is scriptable, I can easily get the above information without using “systemevents”.

Another question also about unscriptable application is that how can i resize the window through applescript. simply setting size property doesn’t work very well, because the window can get “messed up”.

thank you.

hi, anybody any suggestion?

When I used UI browser, it did tell me visible property is there. Strange?