registry

InstallShield: Darwin descriptors

My InstallShield installer doesn't appear to register several of its COM DLLs correctly, even though I have refreshed the COM information for them in the installer. If I manually run regsvr32 after installation, everything is fine. I notice that after installation, I have InprocServer32 values in the registry for my components containi...

Is there a way to use java.util.Preferences under Windows without it using the Registry as the backend?

I want to use the java.util.Preferences API but I don't want my program to attempt to read or write to the Windows registry. How would I go about this? ...

How does COM registration work in Windows

I'm an application packager trying to make sense of how the COM registry keys (SelfReg) interrelate to the given .dll in Windows. ProgID's, AppID's, TypeLibs, Extensions & Verbs are all tied around the CLSID right? Do CLSID's always use Prog/App IDs or could you just have a file extension class? Which bits are optional? Some of it see...

Script to associate an extension to a program

My customer is replacing MS Office with OpenOffice in some workstations. My program export a file to Excel using the .xml extension (using open format) and opens it using the current associated program (using ShellExecute) The problem is that OpenOffice does not register the .xml extension associated with it. Manually association works...

Get XP to automatically "press" the default button on a dialog box

Some time ago, I came across an online article that described how to configure Windows XP to automatically accept the default option on a dialog box. As I (vaguely) recall, it was some sort of oddball registry configuration that did this, and it amazingly worked. Yeah - it's dangerous, but it would be very helpful right now with a proble...

How do you run a program you don't know where the arguments start?

The subject doesn't say much cause it is not easy to question in one line. I have to execute a few programs which I read from the registry. I have to read from a field where somebody saves the whole paths and arguments. I've been using System.Diagnostics.ProcessStartInfo setting the name of the program and its arguments but I've found a ...

Filetype association with application (C#)

Hi, I have a few questions related: 1) Is possible to make my program change filetype association but only when is running? Do you see anything wrong with this behavior? 2) The other option that I'm seeing is to let users decide to open with my application or restore default association ... something like: "capture all .lala files" or...

Anyone using a third-party Windows registry editor that they would recommend to others?

I work with the Windows registry editor (regedit.exe) on a near-daily basis, and occasionally find myself wishing it had more features. For example, it'd be nice if it had: a way to import and export favorites. an advanced search feature that lists all the keys it found, rather than a simple Find feature. It would be great if there w...

Where is a reliable registry key to find install location of Excel 2007?

Where is a reliable registry key to find install location of Excel 2007? ...

Edit Registry Values

Hi, I want to change the registry values on the pocketPC. I ran the following code: if(enabled) { dwData = 120; } if(RegSetValueEx(HKEY_LOCAL_MACHINE, _T("System\\CurrentControlSet\\Control\\Power\\Timeouts\\BattSuspendTimeout"), 0, REG_DWORD, (LPBYTE)&dwData, sizeof(DWORD))) { return FALSE; } but it doesn't shange the regist...

Why is RegOpenKeyEx() returning error code 2 on Vista 64bit?

I was making the following call: result = RegOpenKeyEx(key, s, 0, KEY_READ, &key); (C++, Visual Studio 5, Vista 64bit). It is failing with error code 2 ("File not found") even though "regedit" shows that the key exists. This code has always worked on 32bit XP. Why is it "file not found" when it clearly is there? ...

Using regini from a c# app without bothering the user?

I am developing an application that needs to use regini (because of legacy reasons) to insert something into the registry. I have been trying to do this in such a way the the user of the application is not aware of this. I have written the following code: System.Diagnostics.ProcessStartInfo pi = new ProcessStartInfo(); pi.FileName = ...

CLSIDFromProgID is successful but CreateInstace fails! Why?

I am trying to create an instance of a COM object. I have the class name that implements the interface and I get a CLSID by using CLSIDFromProgID(). So since I am getting a CLSID I thought everything should be fine from now on. However when I do a call to CreateInstance and pass in the CLSID, I get an error saying "Class not registered"....

Set LINQ DSN for DataContext

Hi, I normally store all my configs in the registry. Even though I have started using LINQ I would not like to have the DSN in the web.config, but rather let it stay in the registry and attach it (maybe in the Application Start Event) to the System Config. How can this be done? Thanx for any ideas! edit: to make it clear: I do not wa...

When - and why - should you store data in the Windows Registry?

As a developer, tools that store configuration/options in the registry are the bane of my life. I can't easily track changes to those options, can't easily port them from machine to machine, and it all makes me really yearn for the good old days of .INI files... When writing my own applications, what - if anything - should I choose to p...

How do I read the 'company name' from Windows using C#?

Some programs read the company name that you entered when Windows was installed and display it in the program. How is this done? Are they simply reading the name from the registry? ...

Win32: Registry entries required to register an ActiveX control?

i need write the code that runs when DllRegisterServer is called. i.e. when someone calls: regsvr32 myActiveX.ocx i'm trying to find the definitive list of required registry entries (rather than just what i can cobble together by spellunking through the registry). So far my expeditions have found: HKEY_CLASSES_ROOT \MyCoolLibrary...

Where to store program settings instead of HKEY_LOCAL_MACHINE?

I have some program settings that are currently stored in HKEY_LOCAL_MACHINE. Due to Vista and locked down users, some users don't have permission to HKEY_LOCAL_MACHINE, and those values don't really belong to HKEY_LOCAL_USER either (it has to be the same for all users), what's the best alternative location for storing these? Majority o...

How does CurrentControlSet differ from ControlSet001 and ControlSet002?

In the windows registry, how does CurrentControlSet differ from ControlSet001 and ControlSet002? Which should be set when installing for all users? We are trying to add an environment variable for all users. Should we set: HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Envinronment\EnvToSet? ...

How to search for specific value in Registry keys

Hi, How can I search for specific value in the registry keys? For example I want to search for XXX in HKEY_CLASSES_ROOT\Installer\Products any code sample in C# will be appreciated, thanks ...