Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 238
Default GetSetting and SaveSetting

I can write data to the registry with the following example. I am not
having any luck reading it back and storing it in a worksheet.
Suggestions?
__________________________________

Sub ChangeName(sName As String)
SaveSetting appname:="Euchre", _
section:="PlayerData", _
key:="Name", _
setting:=sName
End Sub

Function GetName()
GetName = GetSetting(appname:="Euchre", _
section:="PlayeData", _
key:="Name")
Range("A1").Value = GetName
End Function

Sub TestIt()
ChangeName "Sick"
MsgBox GetName
End Sub
__________________________________

http://www.dick-blog.com/archives/20...-the-registry/
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 449
Default GetSetting and SaveSetting

You are storing
section:="PlayerData"
and reading
section:="PlayeData"

HTH. Best wishes Harald


"Fan924" wrote in message
...
I can write data to the registry with the following example. I am not
having any luck reading it back and storing it in a worksheet.
Suggestions?
__________________________________

Sub ChangeName(sName As String)
SaveSetting appname:="Euchre", _
section:="PlayerData", _
key:="Name", _
setting:=sName
End Sub

Function GetName()
GetName = GetSetting(appname:="Euchre", _
section:="PlayeData", _
key:="Name")
Range("A1").Value = GetName
End Function

Sub TestIt()
ChangeName "Sick"
MsgBox GetName
End Sub
__________________________________

http://www.dick-blog.com/archives/20...-the-registry/


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default GetSetting and SaveSetting

Its a typo:

section:="PlayeData", _


you're missing the "r" at the end of Player.

Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group, 1998 - 2009
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)


On Sat, 28 Feb 2009 12:24:41 -0800 (PST), Fan924
wrote:

I can write data to the registry with the following example. I am not
having any luck reading it back and storing it in a worksheet.
Suggestions?
__________________________________

Sub ChangeName(sName As String)
SaveSetting appname:="Euchre", _
section:="PlayerData", _
key:="Name", _
setting:=sName
End Sub

Function GetName()
GetName = GetSetting(appname:="Euchre", _
section:="PlayeData", _
key:="Name")
Range("A1").Value = GetName
End Function

Sub TestIt()
ChangeName "Sick"
MsgBox GetName
End Sub
__________________________________

http://www.dick-blog.com/archives/20...-the-registry/

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 238
Default GetSetting and SaveSetting

On Feb 28, 1:02 pm, "Harald Staff" wrote:
You are storing
section:="PlayerData"
and reading
section:="PlayeData"


Error in web page example. That explains it not working. Thanks.
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
SaveSetting: Excel 2000 & 2003 AA2e72E Excel Programming 2 March 14th 06 08:33 AM
GetSetting & HKEY LOCAL_MACHINE [email protected] Excel Programming 2 October 20th 05 05:11 PM
Getsetting and Savesettings James[_38_] Excel Programming 2 June 29th 05 08:05 PM
GetSetting & SaveSetting in Thin Client Environments Stephen Allen[_2_] Excel Programming 1 January 3rd 04 09:22 PM
SaveSetting/GetSetting: not high-overhead? Mark Tangard Excel Programming 1 August 25th 03 12:36 PM


All times are GMT +1. The time now is 07:21 AM.

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"