Jump to content

send ("{APPSKEY}") not getting all memu items from "Component Services" window


Recommended Posts

send ("{APPSKEY}") not getting all memu items from "Component Services" window?

If you press APPSKEY from the keaboard or right click on an item you should get (Export, Start...Properties, Help) but, when you use send ("{APPSKEY}")  you don't get "Properties" which I need to work on.

I've also tried, Send("{SHIFTDOWN}{F10}{SHIFTUP}") and  Send("{LSHIFT}+{F10}") but, no luck!

Link to comment
Share on other sites

Following is the portion of the function from my script.   I'm working on Windows Server 2008 R2 Standard Service Pack 1 with AutoIt v3.3.12.0

-----------------------------

Func _COMPONENT_SERVICE($ENV_C)
   Run("dcomcnfg.exe")
   Sleep(2000)
   WinWaitActive("Component Services")
   Sleep(1000)
   Send("{HOME}")
   Sleep(1000)
   Send("{DOWN}")
   WinWaitActive("Component Services","Component Services")
   Sleep(3000)
   Send("{RIGHT}")
   Send("{DOWN}")
   WinWaitActive("Component Services","\Computers")
   Sleep(2000)
   Send("{RIGHT}")
   Send("{DOWN}")
   WinWaitActive("Component Services","\My Computer")
   Sleep(2000)
   Send("{RIGHT}")
   Send("{DOWN}")
   WinWaitActive("Component Services","\COM+ Applications")
   Sleep(2000)
   Send("{RIGHT}")
   Sleep(2000)
   Send("REPORTS" & $ENV_C)
   WinActive("Component Services","\REPORTS" & $ENV_C)
   Send("{RIGHT}")
   Send("{LSHIFT}+{F10}")  ; This is where I need "Properties",
   ; If you manually press "APPSKEY" or right click from "COM+ Application", you get the "Properties" items in the sub menu.
   ;

Link to comment
Share on other sites

I got it working by accidently!!!  :)

I added a IsAdmin() function to check if the script is running with administrator privileges. This function verified that my script was running with administrator privileges and also it must triggered to run with administrator privileges.  When I removed  IsAdmin() function then, it was not working again.  So, it does not make sense but IsAdmin() function enabled the administrator privileges.:blink:  This has to be a bug!
 

Thanks "Exit" for looking into my problem!  You have a nice day!

Link to comment
Share on other sites

Just a circumvention for the requireadmin problem. Run those two lines to call the program:

$iPid = Run(@ComSpec & " /c " & 'Start dcomcnfg.exe ', "", @SW_HIDE)
    $handle = (WinWait("[Class:MMCMainFrame]", "", 0) ? (WinActivate("[LAST]") ? WinWaitActive("[LAST]") : 0) : SetError(1, 0, 0))

BTW

Send("{LSHIFT}+{F10}")  ; This is where I need "Properties",

does not work. You should use

Send("+{F10}")  ; This will show "Properties",

"+" means SHIFT

Edited by Exit

App: Au3toCmd              UDF: _SingleScript()                             

Link to comment
Share on other sites

Hi EXIT,

I did tried all kinds of way (what pepople from "web/ Internet" said this might work...), including the right way, Send("+{F10}"to show the the property but nothing worked.  This is when I postedthe problem to this Forum. :) 

Anyway, no commands / functions will show properties if you don't put/ use "IsAdmin()" just before using Send("+{F10}").

I know this does not make any sense but, it works.  Like I said I found this by accidently and I'm pretty sure this is a bug!

Thanks.

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...