Hi,
I am writing an installation program for a USB device for windows 2000 and I need to create keys in the registry under :
HKLM\SYSTEM\CurrentControlSet\Enum\USB.
But the when I try to do this, the operation fails with the following error message “Error while opening the Enum key”
Any ideas about how this could be resolved?
Thanks and regards,
Namita.
r u using Setup API ?
SetupDiCreateDevRegKey should do this.
Hi,
I am writing an installation program for a USB device for windows 2000 and I need to create keys in the registry under :
HKLM\SYSTEM\CurrentControlSet\Enum\USB.
But the when I try to do this, the operation fails with the following error message “Error while opening the Enum key”
Any ideas about how this could be resolved?
Thanks and regards,
Namita.
Hello
I am writing an installation program for a USB device for windows 2000 and I need to create keys in the registry under :
HKLM\SYSTEM\CurrentControlSet\Enum\USB.
But the when I try to do this, the operation fails with the following error message “Error while opening the Enum key”
Without any security attributes do you have no rigth to write/delete
any keys here. This part of the registry is only part of the system
and all enumerates USB adapters have here a entry.
This is not a good way to write your information here.
Write information for your adapter like
[…]
HKR,“the keyword”,…
So your USB driver can read this param a start time.
mathias
>I am writing an installation program for a USB device for windows 2000 and
I need to create keys in the registry under :
HKLM\SYSTEM\CurrentControlSet\Enum\USB.
Remake your driver for:
a) assume some default values if there are no real values in the registry.
The driver can be non-functional in this case (if this is absolutely
impossible to do this without the values), but must handle PnP IRPs as
necessary and report success.
Go to fully functional if the values were read successfully by
IoGetDeviceRegistryKey etc.
b) accept an IOCTL from the user mode installation app which will tell real
values to the driver. The driver must then 1) write them to the registry
using IoGetDeviceRegistryKey 2) switch to fully functional mode using the
values.
Also IIRC the device registry key is accessible from the app by some SetupDi
functions.
Max