This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Re: regdbgetkeyvalueex reads garbage string.
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
Jun 24, 2010
02:00 AM
regdbgetkeyvalueex reads garbage string.
hi !!!
I have the following code to read path string from the registry.
-------------------------------------
szKey = "SYSTEM\\CurrentControlSet\\Control\\Session Manager\\Environment";
RegDBSetDefaultRoot(HKEY_LOCAL_MACHINE);
RegDBGetKeyValueEx (szKey, "Path" , nvType, svNumValue, nvSize);
//SprintfBox(MB_YESNO,"TITLE","size : %d, data : %s",nvSize, svNumValue);
nResult = RegDBSetKeyValueEx(szKey, "Path", REGDB_STRING_EXPAND, TARGETDIR^"\\bin\\;" + svNumValue , -1);
--------------------------------------
in Window7 (64 bit),
the svNumValue (after RegDBGetKeyvalueEx) has some garbage string at the end of path string.(like this --> "C:\Program files (x86)\PHP\.........;C:\phython26^!@#$")
This is not occurred in other OS.
I checked the key value manually in the registry.(There is no garbage string)
The garbage string is different every time.
how can I solve this???
Thanks...
I have the following code to read path string from the registry.
-------------------------------------
szKey = "SYSTEM\\CurrentControlSet\\Control\\Session Manager\\Environment";
RegDBSetDefaultRoot(HKEY_LOCAL_MACHINE);
RegDBGetKeyValueEx (szKey, "Path" , nvType, svNumValue, nvSize);
//SprintfBox(MB_YESNO,"TITLE","size : %d, data : %s",nvSize, svNumValue);
nResult = RegDBSetKeyValueEx(szKey, "Path", REGDB_STRING_EXPAND, TARGETDIR^"\\bin\\;" + svNumValue , -1);
--------------------------------------
in Window7 (64 bit),
the svNumValue (after RegDBGetKeyvalueEx) has some garbage string at the end of path string.(like this --> "C:\Program files (x86)\PHP\.........;C:\phython26^!@#$")
This is not occurred in other OS.
I checked the key value manually in the registry.(There is no garbage string)
The garbage string is different every time.
how can I solve this???
Thanks...
(1) Reply