Quick Find: Search for:
Free Resources
from FMS
 

Demos

Email Newsletter

Technical Papers

Tips and Techniques

Links

Book Recommendations

View all FMS products for Microsoft AccessMicrosoft Access Resource Center

 

 

"Thank you! Thank you!
I just finished reading this
document, which was part of a link in the recent Buzz newsletter. I have printed it for others to read, especially those skeptical on the powers of Access and its capabilities.
" 
- Darren D.
 
  

 

Custom Registry Settings in Access

Provided by: Steve Clark, Senior Project Manager

To store a value to the registry, use the SaveSetting command in VBA.

For example:

SaveSetting appname:="MyApp", Section:="Startup", _
Key:="Top", setting:=75

This statement will make a new Key named "MyApp", a sub key named "Startup", a String value named "Top" with a value of "75" in the following location:

HKEY_CURRENT_USER\Software\VB and VBA Program Settings\

To view the change to the registry, click on the Window Start Button and click the Run... option. Enter: Regedit and click OK. The registry will open, and you can browse the tree to locate the entry. (Don't delete or modify anything, as it may have detrimental effects on your system!)

To delete the registry keys that you made, use:

DeleteSetting "MyApp", "Startup"

To retrieve your custom settings, you can use the GetSetting or the GetAllSettings commands.

See the Access Help File for more information.

Return to the tips page.

Questions  l   Web questions: Webmaster   l   Copyright © 2008 FMS, Inc.

Celebrating 21 Years of Software Excellence