Solved

Registry entries

Posted on 2003-11-17
4
425 Views
Last Modified: 2010-05-01
Could someone please explain how to read and write to the registry? I would like to be able to save various settings in the registry. I am creating a program that will need to be run on both win2000 and winXP systems. I have read the msdn entries and tried using the getsetting() and savesetting() functions, but cant find where they actually get saved to!

many thanks,
0
Comment
Question by:Ice123
  • 2
4 Comments
 
LVL 50

Expert Comment

by:Ryan Chong
ID: 9762959
Basically, SaveSetting saved the values into registry: HKEY_CURRENT_USER\Software\VB and VBA Program Settings, to make it more flexible, you must using the existing Registry APIs. Take a look on the links below and try find useful examples

http://www.freevbcode.com/listcode.asp?Category=3
http://www.vbcode.com/asp/code.asp?lstCategory=Registry

Hope this helps
0
 
LVL 9

Expert Comment

by:p_sie
ID: 9762968
They are saved in "My Computer\HKEY_CURRENT_USER\Software\VB and VBA Program Settings".

When saving a setting, you enter the appname, which will be the folder the settings go into.
When useing getsetting you only have to fill in the appname and not the entire registry key
0
 
LVL 11

Accepted Solution

by:
bmatumbura earned 50 total points
ID: 9763343
Also have a look at this Registry Access Class I posted at:

http://www.freevbcode.com/ShowCode.Asp?ID=4330
0
 
LVL 11

Expert Comment

by:bmatumbura
ID: 9769605
Thanks
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now