registry

How to read value of a registry key c#

a 夏天 提交于 2020-01-08 16:02:06
问题 At start up of my application I am trying to see if the user has a specific version of a software installed, specifically the MySQL connector, all using c#. In the registry, the MySQL contains a version entry. So what I am trying to accomplish is this. My app starts up. Somewhere in the start up code I need to do the following things in order. Check to see if the user has the MySQL connector installed, which is located at... HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\MySQL AB\MySQL Connector/Net

Add Application to Startup (Registry)

社会主义新天地 提交于 2020-01-07 09:42:42
问题 I'm trying to add my software to registry, I have found some pieces of the codes I can use but not full working code C/C++ is new to me and can't create it on my own. But here is the basic idea: Check if reg key set if not create it. I was able to get my program location using this code: TCHAR szPath[MAX_PATH]; GetModuleFileName(NULL,szPath,MAX_PATH); And was able to create the key with: (Not sure if it's the right way) HKEY newValue; RegOpenKey(HKEY_CURRENT_USER,"Software\\Microsoft\\Windows

C# get Office ClickToRun Registry Key returns null

China☆狼群 提交于 2020-01-07 09:21:00
问题 I whant to get some Information from the Registry Key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\ClickToRun\Configuration". For some case I do not get the registry key object. For troubleshooting I've tryed the following: RegistryKey k2 = Registry.LocalMachine.OpenSubKey("SOFTWARE"); RegistryKey k3 = Registry.LocalMachine.OpenSubKey("SOFTWARE\\Microsoft"); RegistryKey k4 = Registry.LocalMachine.OpenSubKey("SOFTWARE\\Microsoft\\Office"); RegistryKey k5 = Registry.LocalMachine.OpenSubKey(

How to add batch script to context menu of multiple computers

余生长醉 提交于 2020-01-07 07:56:27
问题 I've been trying to setup a batch script that can be run from the context menu inside a folder. The purpose of the batch script is to populate the folder with a predetermined folder structure. This will need to be replicated on multiple computers(Windows 7-10), so my idea was to have a network share with two batch files and one .reg file. One of the batch files labeled "install.cmd" would copy the other batch file labeled "Subfolders.cmd" to a folder on the C drive, and run the .reg file to

VS 2012 TFS Source Control Explorer - Add Item to Right Click Menu

情到浓时终转凉″ 提交于 2020-01-07 07:16:07
问题 I have written a PowerShell script that takes a single file as an argument and runs a compare to another file in the background. I'd like to be able to right click a file in Team Foundation Server's Solution Explorer, and choose that file as the argument for my script. I've done the exact same thing for files in the Windows Explorer, but I can't quite figure out how to do it for TFS. I thought the registry items to be edited would be located at HKCU\Software\Microsoft\VisualStudio\11.0

To check installed software using a program

匆匆过客 提交于 2020-01-07 03:21:28
问题 We need to create a program ..actually we were asked to create a software licensing compliance tool....How do we check the installed software inside the machine.. Is it through the registry...while searching i saw a post which said we need to look into the "uninstall" subkey of HKLM . Also do we also get information about whether the s/w is freeware ,shareware, licensed from the registry???? We plan to do this using Python and Mysql 回答1: As you already mentioned the list of (properly)

Getting GUID of audio output device (speaker,headphones)

…衆ロ難τιáo~ 提交于 2020-01-07 03:06:57
问题 Is there way to get GUID of device (speaker,headphones) in java? Im trying to modify specific value in registry and i need this key name for instance HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\MMDevices\Audio\Render\{d348b8e8-3118-4a9c-9b43-422647b555ca} Last part {d348b8e8-3118-4a9c-9b43-422647b555ca} is what im looking for. In case its not possible thru java any way to do this with C++? 回答1: The MMDevice API allows you to enumerate audio device endpoints and get their

Context menu handler for folders

做~自己de王妃 提交于 2020-01-07 02:16:45
问题 I am trying to wrap my head around Microsoft's shell extension context menu handler example. Its implementation only shows a context menu on a .cpp file right-click. I want to try to extend it to allow it to show the context menu whenever a folder, drive, or empty space is right-clicked in Explorer as well. So far I was only able to modify it to register right-clicks for all file types, not just .cpp files by specifying * when registering it: hr = RegisterShellExtContextMenuHandler(L"*",

asp.net vb, setting owner on a registry key

匆匆过客 提交于 2020-01-06 18:35:15
问题 I must be an idiot programmer without an example. I am migrating a batch file to a asp.net app, using VB, trying to figure out how in asp.net has wasted almost a day. There is a specific registry key/item I want to change that, by default in Server 2008 and newer, Administrators do NOT have FullControl on. The SetAccessControl function works, as long as I can first set Administrators as the object owner. From the command line it was easy to set the owner as Administrators, then grant

asp.net vb, setting owner on a registry key

ε祈祈猫儿з 提交于 2020-01-06 18:35:11
问题 I must be an idiot programmer without an example. I am migrating a batch file to a asp.net app, using VB, trying to figure out how in asp.net has wasted almost a day. There is a specific registry key/item I want to change that, by default in Server 2008 and newer, Administrators do NOT have FullControl on. The SetAccessControl function works, as long as I can first set Administrators as the object owner. From the command line it was easy to set the owner as Administrators, then grant