Sign in to follow this  
Followers 0
tiny

Explorer Context Menu - Check and Selection

7 posts in this topic

Hi,

I'm trying to write an AutoIt Script which should use an Explorer Context Menu entry.

For example:

File.xyz --> Shift+F10 --> Context Menu appears

--------Entries -------

Open

Explore

Search

...

Test

Now I wanne check if Test exists at target computer. And if it is useable it sould be selected and started.

Can anybody help me? Thanks.

Share this post


Link to post
Share on other sites



Hi,

I'm trying to write an AutoIt Script which should use an Explorer Context Menu entry.

For example:

File.xyz --> Shift+F10 --> Context Menu appears

--------Entries -------

Open

Explore

Search

...

Test

Now I wanne check if Test exists at target computer. And if it is useable it sould be selected and started.

Can anybody help me? Thanks.

Check out the demos in Auto3Lib regarding the handling of popup menus. If you get stuck, post a small example of what you're trying to do in the Auto3Lib thread (Examples forum) and I'll try to help you out.

Auto3Lib: A library of over 1200 functions for AutoIt

Share this post


Link to post
Share on other sites

@Tiny

Maybe this can help you get going.

$objShell = ObjCreate("Shell.Application")
$objFolder = $objShell.Namespace("C:\_\Apps\AutoIT3")
$objFolderItem = $objFolder.ParseName("Test.au3")


$colVerbs = $objFolderItem.Verbs

For $objVerb in $colVerbs
   MsgBox(0,"",$objVerb())
Next

Enjoy !!

ptrex

Share this post


Link to post
Share on other sites

@ptrex

Cool, that's working great. But I have two additional Problems.

First the entry is inside the context menu, but it is greyed out. Can I check if the item is valid?

And second question. Is there an Option to select and run the item if it's valid?

Thanks for your help.

Share this post


Link to post
Share on other sites

Share this post


Link to post
Share on other sites

@Tiny

This is the command to activate it.

$objFolderItem.InvokeVerb("YourNameHere") ;Activates command from the context menu

If it is grayed out it will not run.

regards

ptrex

Thank you again, that works.

I had build a loop whitch tries to start the extension tree times. If the option is greyed out I stop the execution.

Share this post


Link to post
Share on other sites

Wow! I didn't think that it could be done.... Frankly, I began wondering!

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  
Followers 0