Does WPI support parameters to the .hta file?
#1
Posted 30 November 2005 - 03:58 PM
wpi.hta school
would be equivalent to opening wpi.hta and selecting "school" from the Selections drop down.
All the items in the config file that have this would be checked:
configs[pn]=['school']
Does WPI support this right now or would it be easy enough to hack?
Thanks!
#2
Posted 30 November 2005 - 04:09 PM
#3
Posted 01 December 2005 - 09:23 AM
Add these lines to WPI.hta:
<script language="javascript">
var params = oApp.commandLine.split(" ");
var wpiparam=params[params.length - 1];
if( wpiparam!='' ) load_checks = params[params.length - 1];
</script>
#4
Posted 03 December 2005 - 04:16 AM
but , if you write WPI to a CD media , what is the difference for you
between this and checking <school on load> in options .
permanently you will have <school> checked on load .
i think maybe i dont understand your point ?
#5
Posted 07 December 2005 - 11:32 AM
#6
Posted 20 December 2005 - 07:27 AM
i.e. i type in commandline "wpi.hta school install" and then wpi checks school and automagically triggers install action??
EDIT: Figured it out:
<script
language="javascript">
var params = oApp.commandLine.split(" ");
var wpiparam=params[params.length - 1];
if( wpiparam!='' ) {
load_checks = params[params.length - 1];
timer = 'on';
secs = '5';
}
</script>
This post has been edited by cribban: 20 December 2005 - 09:37 AM
#7
Posted 21 December 2005 - 12:29 AM
I want to include commandlines in the next release.
Also where in WPI.hta did you add that section.
#8
Posted 21 December 2005 - 04:06 AM
I added the parameter code, right after the timers.js and before the handleerrors script. When looking at wpi.hta (from version 4.3.5) i added the code at line 111
I'm using WPI for network install here at work and am very happy with it, thanks to your hard work kelsenellenelvian!
#9
Posted 21 December 2005 - 04:12 AM
start /wait %windir%\system32\mshta.exe "%CD%\wpi.hta school"
#11
Posted 21 December 2005 - 04:37 AM
#12
Posted 21 December 2005 - 05:00 AM
#13
Posted 21 December 2005 - 05:08 AM
#14
Posted 21 December 2005 - 05:21 AM
#15
Posted 21 December 2005 - 08:09 AM
<script
language="javascript">
var params = oApp.commandLine.split(" ");
var wpiparam=params[params.length - 2];
var timeparams = oApp.commandLine.split(" ");
var wpitimeparam=timeparams[timeparams.length - 1];
if( wpiparam!='',wpitimeparam!='' ) {
load_checks = params[params.length - 2];
timer = 'on';
secs = timeparams[params.length - 1];
}
</script>
#16
Posted 21 December 2005 - 09:48 AM
#17
Posted 21 December 2005 - 10:36 AM
#18
Posted 21 December 2005 - 01:34 PM
<script
language="javascript">
var params = oApp.commandLine.split(" ");
var wpiparam=params[params.length - 2];
var timeparams = oApp.commandLine.split(" ");
var wpitimeparam=timeparams[timeparams.length - 1];
if (wpiparam!='' && (wpitimeparam!='' && wpitimeparam.length < 4))
{
load_checks = params[params.length - 2];
timer = 'on';
secs = timeparams[params.length - 1];
}
</script>
#20
Posted 22 December 2005 - 02:14 AM
<script
language="javascript">
var params = oApp.commandLine.split(" ");
var wpiparam=params[params.length - 2];
var timeparams = oApp.commandLine.split(" ");
var wpitimeparam=timeparams[timeparams.length - 1];
if (wpitimeparam!='')
{
load_checks = params[params.length -1];
}
if (wpiparam!='' && (wpitimeparam!='' && wpitimeparam.length < 4))
{
load_checks = params[params.length - 2];
timer = 'on';
secs = timeparams[params.length - 1];
}
</script>



Help

Back to top










