Page 1 of 1 1
Topic Options
#10663 - 2001-07-19 05:08 PM How? function and calling it.
^REL^ Offline
Fresh Scripter

Registered: 2001-06-11
Posts: 30
Loc: Netherlands
Hi m8s,

I have a huge loginscript that I want to rewrite and I have so many questions
to ask. But the thing I am figuring out right now is how to make a fuction
for the counting of errors if they occur and to place a new line below the other one.
Coz now the login script is too large and not neat..

Thanks..

code:

$Row = 12 ; What row to place the cursor on
$funk = 0 ; Holds error Numbers

AT ($Row,4) "-> Mapping Home Directory to Drive H: ..."

USE H: /DELETE
USE H: @HOMESHR

IF @ERROR = 0
sleep 1
Color g+/b
AT ($Row,70) " OK.."
$Row = $Row + 1
Color y+/b
ELSE
$funk = $funk + 1
Color r+/b
AT ($Row,70) " Error.."
Color y+/b
$Row = $Row + 1
ENDIF
sleep 1

nlypublic
AT ($Row,4) "-> Mapping Public Directory to Drive P: ..."

USE P: /DELETE
USE P: "\\TNT\Public"

IF @ERROR = 0
Color g+/b
AT ($Row,70) " OK.."
$Row = $Row + 1
Color y+/b
ELSE
$funk = $funk + 1
Color r+/b
AT ($Row,70) " Error.."
$Row = $Row + 1
Color y+/b
ENDIF

AT ($Row,4) "-> Synchronizing Local Clock with Logon Server ..."

SETTIME @LSERVER

Color g+/b
AT ($Row,70) " Ok.. "
$Row = $Row + 1
Color y+/b

USE * /DELETE /PERSISTENT


OhYeah, I also check the client for existence of McAfee virusscanner if not exist
then I do a silent install of the scanner. But I cant get the script to wait until the setup
is completed. The install is rebooting the client after installation. And I get kixscript errors
about to close kix first. Using Kix 3.62.

Any help is appreciated.

After the rewrite I will post the complete script for the people looking for examples.

Greets,
^REL^

_________________________
This is Unix Country. On a quiet night you can hear NT reboot.

Top
#10664 - 2001-07-19 07:33 PM Re: How? function and calling it.
Shawn Administrator Offline
Administrator
*****

Registered: 1999-08-13
Posts: 8611
Hi again - you strange, flying bat-thingy dude

ummm... a quick thing... to get your output messages on new lines, just throw in some ?'s before the string... like this...

? "-> Mapping Home Directory to Drive H: ..."
? " OK.."

-Shawn

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
1 registered (Allen) and 271 anonymous users online.
Newest Members
Sir_Barrington, batdk82, StuTheCoder, M_Moore, BeeEm
17886 Registered Users

Generated in 0.047 seconds in which 0.021 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