Jump to content

Check if class exist


 Share

Recommended Posts

Hey, i am trying to make a check if class exist.. but class name is: "32770" and title is Sandboxie, but another program is runing which title is simuliar to Sandboxie - "Sandboxie Control", so i am trying to make script check when sandboxie exist, which class is "32770"..

I cannot use 

if winexist("sandboxie") then.. because there is sandboxie and sandboxie control, i just need somehow to make it detect when Only sandboxie exist..

Anyone could help me with this?

Link to comment
Share on other sites

  • Moderators

You cannot find unique text to include in your WinExist call? Have you tried WinGetHandle?

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

  • Moderators

So when you hover the AutoIt Window Info Tool, does it return the text? You should be able to use this to specify which of the Sandboxie windows you want.

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

  • Moderators

The text is the second parameter in the WinExists function, e.g. WinExists("Sandboxie", <text in window>). If you look in your AutoIt installation directory you will see Au3Info.exe (Au3Info_X64.exe), this is the AutoIt Window Info tool. Use it to find unique text on the window.

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

32770's are popups of another application.  You can use this to grab it's handle (hparent is the handle of the parent window):

_WinAPI_GetWindow($hParent,6)
Edited by jdelaney
IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window.
Link to comment
Share on other sites

  • Moderators

How this will work?

 

At some point you need to try it on your own. We can only spoon-feed so much.

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...