Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 300
Default Saving parameters in the Registry?

Someone gave me some code to manage the storing of parameters in the
registry. I sent him an e-mail asking how to use the macros, but I got back
an out-of-office message saying he would be away until June 15th.

My problem is the functions have no documentation for the arguments. So I
have no idea how to use them. I can send anyone interested the workbook
with them all. The functions with their arguments a

Function QueryValueEx(ByVal lhKey As Long, ByVal szValueName As String,
vValue As Variant) As Long

Public Function CreateNewKey(sNewKeyName As String, lPredefinedKey As Long)

Public Function SetKeyValue(sKeyName As String, sValueName As String,
vValueSetting As Variant, lValueType As Long)

Public Function QueryKey(sKeyName As String, sValueName As String)

On a Workbook_Open I'd like to see if the registry key exists, if not then
to create it and set it to a value of two. If it exists I'd like to read
the value and put it in the range FirstMenu.

Then in the Workbook_BeforeSave event I like to store the value found in
the range FirstMenu. The name of the application is ASF. How would I call
these functions? (I'm using xl2002.)

Don <www.donwiss.com (e-mail link at home page bottom).
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Saving parameters in the Registry?

Don,
You may find it easier using a class wrapper. Steve McMahon's is easy to
use:
http://www.****alshah.com/vbxlr/code...g/registry.htm

NickHK

"Don Wiss" wrote in message
...
Someone gave me some code to manage the storing of parameters in the
registry. I sent him an e-mail asking how to use the macros, but I got

back
an out-of-office message saying he would be away until June 15th.

My problem is the functions have no documentation for the arguments. So I
have no idea how to use them. I can send anyone interested the workbook
with them all. The functions with their arguments a

Function QueryValueEx(ByVal lhKey As Long, ByVal szValueName As String,
vValue As Variant) As Long

Public Function CreateNewKey(sNewKeyName As String, lPredefinedKey As

Long)

Public Function SetKeyValue(sKeyName As String, sValueName As String,
vValueSetting As Variant, lValueType As Long)

Public Function QueryKey(sKeyName As String, sValueName As String)

On a Workbook_Open I'd like to see if the registry key exists, if not then
to create it and set it to a value of two. If it exists I'd like to read
the value and put it in the range FirstMenu.

Then in the Workbook_BeforeSave event I like to store the value found in
the range FirstMenu. The name of the application is ASF. How would I call
these functions? (I'm using xl2002.)

Don <www.donwiss.com (e-mail link at home page bottom).



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 300
Default Saving parameters in the Registry?

On Fri, 26 May 2006 11:07:44 +0800, NickHK wrote:

Don Wiss wrote:
Someone gave me some code to manage the storing of parameters in the
registry. I sent him an e-mail asking how to use the macros, but I got back
an out-of-office message saying he would be away until June 15th.

My problem is the functions have no documentation for the arguments. So I
have no idea how to use them.


You may find it easier using a class wrapper. Steve McMahon's is easy to
use:
http://www.****alshah.com/vbxlr/code...g/registry.htm


I found that to be overkill for my needs. And the functions I found in the
Class Module also lacked documentation. So I searched on google on one of
the function names I had. I found that the functions I was given came from
this web page:

http://support.microsoft.com/default...145679&sd=tech

And on this page they give examples, so I was able to figure it out.

Don <www.donwiss.com (e-mail link at home page bottom).
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Saving Text to Columns parameters for future use Denise Groves Excel Discussion (Misc queries) 3 October 12th 06 11:07 PM
Value from Registry Roy Lasris Excel Programming 3 February 23rd 04 11:53 PM
Saving Registry variable to ini file Allen[_3_] Excel Programming 0 September 10th 03 06:14 PM
Registry Tom Ogilvy Excel Programming 1 July 16th 03 01:02 AM
Registry Patrick Molloy[_4_] Excel Programming 0 July 15th 03 12:45 PM


All times are GMT +1. The time now is 02:32 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"