Insert Function in Build-ContextMenu


hello , thanks, please have powershell script create menu options :

$objcontextmenu | build-contextmenu -index 0 -text "notepad" -action "c:\windows\notepad.exe"
$objcontextmenu | build-contextmenu -index 1 -text "notepad" -action "c:\windows\notepad.exe"
$objcontextmenu | build-contextmenu -index 2 -text "help" -action "c:\windows\winhlp32.exe"

but need launch function instead of open program this

$objcontextmenu | build-contextmenu -index 0 -text "function" -action (i want launch function here when user click menu)

any suggestions??? thank you!!!!!!!!!!


what build-contextmenu function you're talking about?

if it's custom, you'll either need ask author or post link.


don't retire technet! - (don't give yet - 12,575+ strong , growing)



Windows Server  >  Windows PowerShell



Comments

Popular posts from this blog

server manager error: ADAM.events.xml could not be enumerated.

Cannot access Anywhere Access using domain name?

WMI Failure: Unable to update Local Resource Group