MarkSLC Posted December 19, 2005 Posted December 19, 2005 What script would I use to check if a certain layout or a certain window (via its title) is open? Thx.
aaa Posted December 19, 2005 Posted December 19, 2005 Hi, MarkSLC! Is there reason to know is open or not? If you need to open - open it, or if you want to close - close it, without knowing it is open or close.
MarkSLC Posted December 19, 2005 Author Posted December 19, 2005 Hi. Yeah, I have some scripts that depend on knowing whether the window is open and the information available to the user, and if the window is taking up screen real estate. I started out by setting a global variable "flag." The user clicks a button, the New Window() opens, the flag = true. The user clicks the same button (a toggle), the window closes, the flag = false. The problem? The user can click the window's close button (of the close/minimize/maximize buttons), and I would not know the window is gone.
aaa Posted December 19, 2005 Posted December 19, 2005 Dont use your button for clossing window(use system clossing button(close/minimize/maximize buttons)). Your button use only for opening window.
BrentHedden Posted December 19, 2005 Posted December 19, 2005 Use the WindowNames {( fileName )} function. This returns a carriage returned delimitated listing of all the current windows that are open. More specifically, the window's titles. All you have to do is run a patterncount against this function for what you're looking for.
MarkSLC Posted December 20, 2005 Author Posted December 20, 2005 Perfect. Thanks Brent for helping me solve this one.
Fitch Posted December 20, 2005 Posted December 20, 2005 You may find this custom function useful: http://www.clevelandconsulting.com/support/viewtopic.php?t=287
Recommended Posts
This topic is 6915 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now