How to use the Windows Script Host to read, write, and delete registry keys (244675)
The information in this article applies to:
- Microsoft Visual FoxPro for Windows 3.0
- Microsoft Visual FoxPro for Windows 3.0b
- Microsoft Visual FoxPro for Windows 5.0
- Microsoft Visual FoxPro for Windows 5.0a
- Microsoft Visual FoxPro for Windows 6.0
- Microsoft Visual FoxPro for Windows 7.0
- Microsoft Visual FoxPro 8.0
- Microsoft Visual FoxPro 9.0 Professional Edition
This article was previously published under Q244675 SUMMARYImportant This article contains information about modifying the registry. Before you modify the registry, make sure to back it up and make sure that you understand how to restore the registry if a problem occurs. For information about how to back up, restore, and edit the registry, click the following article number to view the article in the Microsoft Knowledge Base: 256986 Description of the Microsoft Windows Registry
The Microsoft Windows Script Host (WSH) is a tool that allows you to run Microsoft Visual Basic Scripting Edition and Microsoft JScript natively within the base operating system, either on Microsoft Windows 95 or Microsoft Windows NT 4.0. It also includes several COM automation methods that allow you to do several handy tasks easily through the Windows Script Host Object Model.
The Microsoft Windows Script Host is integrated in Windows 98. It is available for Windows NT 4.0 from within the Windows NT 4.0 Option Pack.
It is also available for download from the following site:
The Windows Script Host provides several useful methods to read, write, and delete registry keys easily. The RegWrite function's third parameter allows the programmer to specify the type of data added to the registry. RegWrite supports strType as REG_SZ, REG_EXPAND_SZ, REG_DWORD and REG_BINARY. If another data type is passed as strType, RegWrite returns E_INVALIDARG.
REFERENCESTo see the following white papers: - White paper:
Windows Script Host: A Universal Scripting Host for scripting languages
- Technical paper: Windows Script Host programmer's reference
visit the following Microsoft Developer Network (MSDN) Web site:
For additional information about using Visual FoxPro and the Windows Script Host, click the following article number to view the article in the Microsoft Knowledge Base:
244677
How to create a Desktop shortcut using the Windows Script Host
244676 How to map, delete and enumerate network drives using the Windows Script Host
Modification Type: | Major | Last Reviewed: | 1/25/2005 |
---|
Keywords: | kbCodeSnippet kbhowto KB244675 kbAudDeveloper |
---|
|