Just for the record:
The path "C:\Documents and Settings\Username\LocalService\Application Data" 
does NOT exist on my system.
WinXP Pro SP1. Swedish.
Unless you meant "C:\Documents and Settings\Username\LocalService\Application 
Data" in which case "LocalService" is language
specific.

Better to use the environment variables to get sys folders.

In addition to the sysfolders in Buddy's help, you can find more by running 
this handler:

on showSysFolders
   repeat with i = 0 to 60
     put i, baSysFolder(string(i))
   end repeat
end
-----


So:
put baSysFolder("28")
"C:\Documents and Settings\Bertil Flink\Lokala inst�llningar\Application Data\"

on an English system that would be:
"C:\Documents and Settings\Bertil Flink\\LocalService\Application Data"


More info from Gary himself:

"As well as the above folders, you can also pass in the number of a special
folder. These numbers are listed in the ShlObj.h header file in the Windows
Platform SDK. For example, to get the Cookies folder, you can use
baSysFolder( "33" ). If you pass in a number, it will be passed directly to
the SHGetSpecialFolderLocation API call."

and

"OnWindows, if using buddy 3.6 you can use:

baSysFolder( "26" )

To get the application data folder. Otherwise it is in the registry at
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\She
ll Folders\AppData


On OSX, if you are using buddy 1.4c then

baSysFolder( "asup" )

Will give you the right folder. It is on the boot disk, at

/Library/Application Support "

--------

Thanks to Daniel Nelson & Sean Wilson for posting some of this info back in 
2003/2004.




Bertil Flink
Creative Media





----- Original Message ----- 
From: "Cole Tierney" <[EMAIL PROTECTED]>
To: "Lingo programming discussion list" <[email protected]>
Sent: Friday, June 10, 2005 7:24 PM
Subject: RE: <lingo-l> set/getpref in projector on locked down Windows systems?


> At 11:56 AM -0400 6/10/05, Mendelsohn, Michael wrote:
> >-- XP, returns a path ALWAYS available to write to: "C:\Documents and
> >Settings\LocalService\Application Data"
> >   theAppData =
> >baReadRegString("Software\Microsoft\Windows\CurrentVersion\Explorer\Shel
> >l Folders","AppData","Error","HKEY_CURRENT_USER")
> >
> >>From there, I use FileIO to write all my data.
>
> Thanks for the advice, Michael. I'll probably do something similar in
> the end. At this point, I'm driven mostly by curiosity. And my lazy
> side would prefer to only use setpref. ;) I'll whip up a little test
> projector and see how far I push setpref.
>
> -- 
> Cole

>

[To remove yourself from this list, or to change to digest mode, go to 
http://www.penworks.com/lingo-l.cgi  To post messages to the list, email 
[email protected]  (Problems, email [EMAIL PROTECTED]). Lingo-L is for 
learning and helping with programming Lingo.  Thanks!]

Reply via email to