Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Writing to the registry during setup - vfp6
Message
From
04/12/2002 12:19:55
Doug Denison
Alternate Solutions
Oregon, United States
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Writing to the registry during setup - vfp6
Miscellaneous
Thread ID:
00729505
Message ID:
00729505
Views:
199
Hello,
I am working on a VFP6 software package that we distribute on CD with setup and runtime libs. One of the steps I am trying to add to the setup is to update the registry. I have tried the windows scripting and the Win32 API functions both of which gave me the same results. They work fine in Foxpro interactively but both methods write the "EditFlags" values as REG_BINARY when I run them from my setup.exe. Here is the code from my first attempt:

oShell = Createobject("WScript.Shell")
=oshell.RegWrite("HKEY_CLASSES_ROOT\Visual.FoxPro.Application.6\EditFlags",0,"REG_DWORD")
=oshell.RegWrite("HKEY_LOCAL_MACHINE\Software\Classes\Visual.FoxPro.Application.6\EditFlags",0,"REG_DWORD")
=oshell.RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Updates\VFPODBC\Q326568\","Microsoft ODBC Driver QFE Q326568")
=oshell.RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Updates\VFPODBC\Q326568\Installed",1,"REG_DWORD")
=oshell.RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Updates\VFPODBC\Q326568\Description","Microsoft ODBC Driver QFE Q326568")
=oshell.RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Updates\VFPODBC\Q326568\Type","Update")

Again...I also used the registry program by Rick Strahl which uses the Win32 API calls but got the same result.

Any help with this would be appreciated.

Thanks
Next
Reply
Map
View

Click here to load this message in the networking platform