Jump to content
Sign in to follow this  

Is there some benefit to "If Not WinActive()"?

Recommended Posts


e.g. code:

If Not WinActive("mywindow", "") Then WinActivate("mywindow", "")

Is there some benefit (speed and/or reliability and/or anything else) to doing this instead of simply?


all my code is in latter style but if there is some benefit I would probably rewrite it.


Share this post

Link to post
Share on other sites


I always deploy: "If something neednt be done, why do it" kind of logic

----------------------------------90% of teens today would die if Myspace,Bebo + FaceBook had a system failure and was completely destroyed. If you are one of the 10% that would be laughing, copy and paste this to your signature.----------------------------------Code to win, 'till you die, 'till the compiler dies from your linesCode to win, take it all, just keep coding till you fallDay by day, codin' all the way, I'm not cavin' inLet another App begin, code to win

Share this post

Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.