Page 1 of 1 1
Topic Options
#48215 - 1999-09-24 07:52 AM Check for string in ini file
Anonymous
Unregistered


I have a script which adds some lines to a ini file, when the user logs on the first time. But the next time the user logs on I don't want the lines to be added once more.

Anyone which have an idea how to make this work ?

Top
#48216 - 1999-09-24 08:37 AM Re: Check for string in ini file
Anonymous
Unregistered


Look at the READPROFILESTRING function.

Darryl Jacoby, MCSE

Top
#48217 - 1999-09-25 12:11 AM Re: Check for string in ini file
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
Or, you can add a "cookie" to the users profile like so...

code:

if readvalue ( "software\scripts", "completed" ) <> "yes"
?"Update ini code goes here..."
$rs = addkey ( "software\scripts" )
$rs = writevalue ( "software\scripts", "completed", "yes", "reg_sz" )
else
?"Already done !"
endif

Shawn.


Top
Page 1 of 1 1


Moderator:  Glenn Barnas, NTDOC, Arend_, Jochen, Radimus, Allen, ShaneEP, Ruud van Velsen, Mart 
Hop to:
Shout Box

Who's Online
1 registered (Henriques) and 2516 anonymous users online.
Newest Members
fgarcia, Viginette, ManuvdWielNL, Sir_Barrington, batdk82
17889 Registered Users

Generated in 0.049 seconds in which 0.023 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org