Page 1 of 1 1
Topic Options
#176230 - 2007-05-12 06:47 PM SUBSTR usage help please
FullBoost Offline
Fresh Scripter

Registered: 2007-05-04
Posts: 13
Ok I am super new to Kix and trying my best to understand everything so please bear with me on this. We had a guy that left our company that used kix for our logon script. I am getting ready to rewrite it and add some new functions.
I have searched around and cannot get a clear answer as to what these commands do:

SUBSTR(@WKSTA,1,4)

SUBSTR(@userid,1,9)

I think SUBSTR(@WKSTA,1,4) is looking for a specific workstation name but what is the ,1,4 for?
Same with the next one I think SUBSTR(@userid,1,9) is looking for a specific username but what is the ,1,9 for?

I know this must be super basic but it would help me understand what he has going on in his scripts.

Thank You

Top
#176231 - 2007-05-12 07:03 PM Re: SUBSTR usage help please [Re: FullBoost]
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
 Originally Posted By: FullBoost
I have searched around and cannot get a clear answer as to what these commands do:
Did you look at page 108 of the manual? It provides a clear explanation of the parms "string",start,length.

The first line is looking only at the first 4 chars of the computer name while the second line looks at the first 9.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
Page 1 of 1 1


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

Who's Online
0 registered and 1452 anonymous users online.
Newest Members
Viginette, ManuvdWielNL, Sir_Barrington, batdk82, StuTheCoder
17888 Registered Users

Generated in 0.051 seconds in which 0.025 seconds were spent on a total of 13 queries. Zlib compression enabled.

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