Welcome to Dream.In.Code
Getting VB Help is Easy!

Join 136,538 VB Programmers for FREE! Get instant access to thousands of VB experts, tutorials, code snippets, and more! There are 1,761 people online right now. Registration is fast and FREE... Join Now!




Adding custom command to Explorer Shell

 
Reply to this topicStart new topic

Adding custom command to Explorer Shell

jclegg42002
21 Aug, 2008 - 06:01 AM
Post #1

New D.I.C Head
*

Joined: 14 Aug, 2008
Posts: 10


My Contributions
CODE
Dim WSHShell
Set WSHShell = WScript.CreateObject("WScript.Shell")

WSHShell.RegWrite "HKCR\Folder\Shell\rootexplore\Command\", "cmd.exe /k" & chr(34) & "runas /user:" + "AM\" & "%USERNAME%" & "-ds"
WSHShell.RegWrite "HKCR\Folder\Shell\rootexplore\", "Runas With -ds Account"


I want to be able to right click on a File, not a folder and this command be available? Any advice? Regular .vbs

Does anyone know where the key is for file shell instead of folder, file directory is in that registry tree, but not similar to Folder. Thanks!
User is offlineProfile CardPM
+Quote Post

perfectly.insane
RE: Adding Custom Command To Explorer Shell
21 Aug, 2008 - 05:13 PM
Post #2

D.I.C Addict
Group Icon

Joined: 22 Mar, 2008
Posts: 558



Thanked: 46 times
Dream Kudos: 25
Expert In: C/C++

My Contributions
Yes.. it's under "*" (as in, HKCR\*\shell\yourkey\command).
User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic
Time is now: 12/2/08 10:28PM

Live VB Help!

VB Tutorials

Reference Sheets

VB Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month