Runtime changing values in Registry

I am changing the values in the registry runtime... But the dll is not getting invoked even if the values are changed successfully.

Vicky... :-)

Reply to
Vicky
Loading thread data ...

What registry values are you changing? When are you changing them? How are you changing them? what is your expected result?

Glenn Adams Tiber Creek C> I am changing the values in the registry runtime... But the dll is not

Reply to
Glenn Adams [MVP - Retail Mgmt]

Reply to
ozzie

I've used the following code to enter into the registry.... I've written this code in the Process function of StartPOS....

Dim regKey As RegistryKey Dim ver As Decimal regKey = Registry.LocalMachine.OpenSubKey("Software\Microsoft\Retail Management System\Store Operations\Hooks\001", True) regKey.SetValue("Caption", "InitializeTransaction") regKey.SetValue("Description", "Test this") regKey.SetValue("HookType", "6") regKey.SetValue("ObjectName", "ClassLibrary1.Tender") regKey.SetValue("Parameter", "1") regKey.Close()

The values in the registry are entered properly but to reflect to the application I need to restart the application... Is there any other way out... ?? :-(

I want to write the values when the POS starts, and when I press the Tender button the newly added registry method shld get invoked....

Vicky... :-)

"Glenn Adams [MVP - Retail Mgmt]" wrote:

Reply to
Vicky

The hooks are only read from the registry at startup. Setting them like this is not going to make them available until POS is restarted. Also, you need to set the Hook Count. If the Hook Count is 0, all of your hooks will be removed from the registry - if it's 1, all except Hook 0 will be removed...

You should do the registry entries as part of a setup/install process, not as a runtime operations.

Glenn Adams Tiber Creek C> I've used the following code to enter into the registry.... I've written this

Reply to
Glenn Adams [MVP - Retail Mgmt]

BeanSmart website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.