Page 1 of 1 1
Topic Options
#17732 - 2002-02-20 11:37 PM Annoyances....
oclayton Offline
Fresh Scripter

Registered: 2002-01-24
Posts: 12
ok. have the script set up in the netlogon share. have a batch file (below) to call the script. Script runs fine. But two problems:
1. It seems to take forever--much longer than our normal logon.bat file ever did.
2. It opens a cmd window with a "0" in the upper left hand corner.
Both are annoying me to no end!!

I would like to see the script sped up considerably and would also like to not have the command window appear if that's possible. I tried the "start /min" but not too crazy about the way that looks either.

The script and the bat file that call the script are below.

Thanks...
oclayton


Bat File~~~~~~~

code:
 

@ECHO OFF
START /MIN %0\..\kix32.exe TESTKIX.kix
end



Script~~~~~~

code:
  
SETTIME \\RPSIES01

$hour=val(substr(@TIME,1,2))
Select
Case $Hour<12
? 'Good Morning'
Case $Hour<18
? 'Good Afternoon'
Case 1
? 'Good Evening'
EndSelect


WriteValue("HKEY_CLASSES_ROOT\CLSID\{20D04FE0-3AEA-1069-A2D8-08002B30309D}","","My Computer %computername%","REG_SZ")

USE H: "\\houston\@userid$$"
USE K: "\\houston\mapp2"
USE M: "\\houston\mrcommon"
USE Y: "\\houston\apps"


IF INGROUP ("Marketing") > 0
USE I: "\\houstonsnap\mrdocs"
USE U: "\\houstonsnap\rpsidocs"
ENDIF

IF INGROUP ("Accounting") > 0
USE J: "\\houston\mracct"
USE P: "\\houston\mrbud"
ENDIF

IF INGROUP ("Rep Services") > 0
USE L: "\\houston\mrrepsrv"
ENDIF

IF INGROUP ("Sales") > 0
USE L: "\\houston\mrrepsrv"
ENDIF

IF INGROUP ("Merchant Services") > 0
USE O: "\\cpp01\mrcadre"
ENDIF

IF INGROUP ("AspectR") > 0
USE R: "\\rpsisna\as890360"
ENDIF

IF INGROUP ("Tech") > 0
USE T: "\\houston\mrtech"
ENDIF

IF INGROUP ("Agent Bank") > 0
USE V: "\\houston\mragentb"
ENDIF

IF INGROUP ("HR") > 0
USE W: "\\houston\mrhrshr"
ENDIF

IF INGROUP ("Compliance") > 0
USE X: "\\houston\mrcntrt"
ENDIF



Top
#17733 - 2002-02-21 12:08 AM Re: Annoyances....
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11165
Loc: Boston, MA, USA
Norton Antivirus can slow down a script by a factor of 10. See post http://kixtart.org/cgi-bin/ultimatebb.cgi?ubb=get_topic&f=1&t=002912

Also, this line WriteValue("HKEY_CLASSES_ROOT\CLSID\{20D04FE0-3AEA-1069-A2D8-08002B30309D}","","My Computer %computername%","REG_SZ") causes the display of a '0' in your command windows since this is the return code. Proper coding would assing a variable to the returncode like: $retcode=writevalue(...)

[ 21 February 2002: Message edited by: sealeopard ]

_________________________
There are two types of vessels, submarines and targets.

Top
#17734 - 2002-02-21 01:07 AM Re: Annoyances....
Radimus Moderator Offline
Moderator
*****

Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
you could also copy the kix32 executable to the client machine before running the script.

START /MIN %windir%\kix32.exe %0\..\TESTKIX.kix

_________________________
How to ask questions the smart way <-----------> Before you ask

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 1409 anonymous users online.
Newest Members
Viginette, ManuvdWielNL, Sir_Barrington, batdk82, StuTheCoder
17888 Registered Users

Generated in 0.052 seconds in which 0.026 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