Application Launch Key

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I need to set a key (ex. F1 Key) to launch pword.exe when pressed. I was doing this with a RegisterHotKey command, but this only works when my application is running. I think I need to set a Registry Key instead, as this Key needs to launch pword.exe all the time, not just when my app is running. Does anyone have any examples of setting a Registry Key? I am pretty sure I would use the RegCreateKeyEx function, but I am confused as to what all the parameters are expecting. Any help is appreciated. Thanks.
 
You don't have to call RegCreateKeyEx, you could call RegCreateKey, it should do what you want to do. I don't know how this function will work in VB.NET. There are .NET classes to edit registry key's so technically RegCreateKey/Ex API is the most complicated way to edit the registry if you're not used to dealing with handles, WIN API, etc.

Mark
 
What is the difference in RegCreateKeyEx and RegCreateKey? I can't find just RegCreateKey in my documentation. You said there were .Net classes to edit the registry, what are they? I am totally lost. Thanks for your help, sorry to be so ignorant about this, but I haven't worked with the registry before.
 
* "=?Utf-8?B?QVdhdGtpbnM=?= said:
I am pretty sure I would use the RegCreateKeyEx function, but I am
confused as to what all the parameters are expecting.

For registry access, have a look at 'Microsoft.Win32.Registry'.
 
Back
Top