Page 1 of 1 1
Topic Options
#29108 - 2002-09-16 04:11 PM Shell Question
Rook Offline
Fresh Scripter

Registered: 2002-09-12
Posts: 7
Loc: Worthington OH
I am using shell to run an office 2000 unattended setup using a transform file. My problem is when the setup starts the script continues to exicute.

IF KEYEXIST("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\9.0")
? "Microsoft Office 2000 Professional Installed...."
ELSE
SHELL "\\JACOB_FILE01\TD$\Technology_Department\Applications\Office2000\Setup.exe TRANSFORMS=setup.mst /qb+"
ENDIf

Any ideas why this would be happening.

Thanks Brian.

Top
#29109 - 2002-09-16 04:16 PM Re: Shell Question
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11165
Loc: Boston, MA, USA
Yes.

See for example Not quite everything you wanted to know about RUN and SHELL or the SHELLCMD() - Executes a shell command UDF.

You need to force thew SHELL to wait for the called application to finish before returning control back to KiXtart. Thus, you force it with SHELL '%COMSPEC% /e:1024 /c START /MIN /WAIT '+$appcommand
_________________________
There are two types of vessels, submarines and targets.

Top
#29110 - 2002-09-16 04:18 PM Re: Shell Question
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
Are you using Wkix32.exe or Kix32.exe?

If you are using Kix32.exe:
Just guess but setup.exe might be spawning a separate process and setup then returns control to the script satisfying the SHELL's wait requirement.

You may want to try "%comspec% /c start /wait ..."
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#29111 - 2002-09-16 05:17 PM Re: Shell Question
Rook Offline
Fresh Scripter

Registered: 2002-09-12
Posts: 7
Loc: Worthington OH
is this the proper syntax? SHELL '%comspec% /e:1024 /c /wait "\\JACOB_FILE01\TD$\Technology_Department\Applications\Office2000\Setup.exe TRANSFORMS=setup.mst /qb+"'
Top
#29112 - 2002-09-16 05:45 PM Re: Shell Question
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
rook you don't need the e switch but you need the wait which comes with start.
SHELL '%comspec% /c start /wait "\\JACOB_FILE01...
_________________________
!

download KiXnet

Top
#29113 - 2002-09-16 05:46 PM Re: Shell Question
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11165
Loc: Boston, MA, USA
I prefer to code full paths, thus
code:
SHELL '%comspec% /e:1024 /c START /MIN /WAIT 
"\\JACOB_FILE01\TD$\Technology_Department\Applications\Office2000\Setup.exe"
TRANSFORMS="\\JACOB_FILE01\TD$\Technology_Department\Applications\Office2000\setup.mst" /qb+'

however, I am using the following line which pulls appropriate MSIs from one location, customized MSTs from a second location and writes a log file and install for all users under an administrative account. I do install diffeent Office suites on different computers, for example, Office+Frontpage for our Webiste Development Computer.
code:
SHELL '%comspec% /e:1024 /c START /MIN /WAIT msiexec.exe /I 
"\\SERVER\msi$\Microsoft Office 2000 Premium\data1.msi" /QB- /LWAMOE
"%TEMP%\office2000_frontpage_install.log"
TRANSFORMS="\\SERVER\kixtart_maintenance$\deploy\msoffice2k\office2000_frontpage_install.mst" ALLUSERS=1'

codelines wrapped for readability
_________________________
There are two types of vessels, submarines and targets.

Top
#29114 - 2002-09-16 10:27 PM Re: Shell Question
Rocco Capra Offline
Hey THIS is FUN
*****

Registered: 2002-04-01
Posts: 380
Loc: Mansfield Ohio
I've tried all the suggestions here but still cannot get SHELL to wait...
code:
$PC = ""
? "[ Enter a Computer name ] :"
GETS $PC

SHELL '%COMSPEC% /C explorer.exe "http://'+$PC+':5800"'

I also tried using iexplore.exe to no avail.
Any suggestions.

Rocco

(Trying to get alterntive in my distributable VNC script in case user does not have vncviewer.exe for one reason or another,like they delete it or something.)
_________________________
I Love this board!! -------------------- My DEV PC is running KIX 4.22 WINXP Pro

Top
#29115 - 2002-09-16 10:32 PM Re: Shell Question
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11165
Loc: Boston, MA, USA
Did you use '%COMSPEC% /c /e:1024 START /MIN /WAIT'+$appcall ?

The START segment is requried to force waiting.
_________________________
There are two types of vessels, submarines and targets.

Top
#29116 - 2002-09-16 10:33 PM Re: Shell Question
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Well if it's a VNC instaler you want, check this out.

Topic: OFF TOPIC: Hyena 4.3 is out
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#29117 - 2002-09-16 10:34 PM Re: Shell Question
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
yeah, I see no wait nor start in your call rocco...
the environment is not needed though, but as jens pulls it everywhere...
well, it does not harm either.
_________________________
!

download KiXnet

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 302 anonymous users online.
Newest Members
Sir_Barrington, batdk82, StuTheCoder, M_Moore, BeeEm
17886 Registered Users

Generated in 0.149 seconds in which 0.076 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