Batch file Popup
Hi...
created my package in wise WPS. During the installation of the package a batch file runs (using CA - execute program from destination, Normal execute immediate/Deferred, Location just "before" InstallFinalize) and outputs the result into a file. how can I create message box(popup) with that output so if the batch file result in error installation does not continue and fails and informs the user.
any suggestions would be highly appreciated.
Thank You! [:)]
created my package in wise WPS. During the installation of the package a batch file runs (using CA - execute program from destination, Normal execute immediate/Deferred, Location just "before" InstallFinalize) and outputs the result into a file. how can I create message box(popup) with that output so if the batch file result in error installation does not continue and fails and informs the user.
any suggestions would be highly appreciated.
Thank You! [:)]
0 Comments
[ + ] Show comments
Answers (11)
Please log in to answer
Posted by:
anonymous_9363
13 years ago
Forget batch and use script. You can embed script into the package, there's much better error handling, plus access to the package's properties, etc., etc., etc. Please avoid the "I don't know script" argument: you won't last long as a packager (or even as a general support Johnnie) without scripting skills.
Having said that, what is the batch file doing? Can its activity not be incorporated into the package itself?
Having said that, what is the batch file doing? Can its activity not be incorporated into the package itself?
Posted by:
pjgeutjens
13 years ago
My preferred way of working is to have the script return an exit code 3 upon failure. Then have the CA check the script's exit code before continuing. If it fails the exit code 3 will trigger a rollback of the installer.
As far as the popup goes, it might be a better idea to just log the failure in the MSI's installation log, rather than show an actual popup. You should be able to find plenty of examples on how to write to the installation log from a CA.
Rgds,
PJ
As far as the popup goes, it might be a better idea to just log the failure in the MSI's installation log, rather than show an actual popup. You should be able to find plenty of examples on how to write to the installation log from a CA.
Rgds,
PJ
Posted by:
Netrock
13 years ago
Posted by:
Netrock
13 years ago
Hi,
Still working on this issue and need a light to find the way. [8|]
i made my package it is working fine. but i need to add a condition before the installation continues. to do this, i have a batch file it checks the DNS entry of the workstation.
If the Forward or Reverse lookup fails the user should be notified and the installation must be terminated. So how can i do this in wise package. the user should be advised if the reverse or forward lookup failed.
I really need to find the right direction to do this.
your help highly appreciated.
Thanks.
Still working on this issue and need a light to find the way. [8|]
i made my package it is working fine. but i need to add a condition before the installation continues. to do this, i have a batch file it checks the DNS entry of the workstation.
If the Forward or Reverse lookup fails the user should be notified and the installation must be terminated. So how can i do this in wise package. the user should be advised if the reverse or forward lookup failed.
I really need to find the right direction to do this.
your help highly appreciated.
Thanks.
Posted by:
AngelD
13 years ago
Posted by:
Netrock
13 years ago
Thanks AngelID for your reply.[;)]
have more questions if you can answer i appreciate.
Let's say i create a VBscript to call the batch file as follows:
Function AngelID()
dim shell
set shell=createobject("wscript.shell")
shell.run "batchfile.cmd.bat"
set shell=nothing
End Function
Next in wise I select the Action: Call "VBscript from Installtion" Next i have the details, location and the properities tabs
could you please advise:
1) in Details tab what i should put for "Script Function Call"
2) where to set the selection and whato enter for the "Condition:" Box
3)in properities tab i will select for PROCESSING option: Synchronous. Is this ok?
Thank you in adavnce for your help.[:D]
have more questions if you can answer i appreciate.
Let's say i create a VBscript to call the batch file as follows:
Function AngelID()
dim shell
set shell=createobject("wscript.shell")
shell.run "batchfile.cmd.bat"
set shell=nothing
End Function
Next in wise I select the Action: Call "VBscript from Installtion" Next i have the details, location and the properities tabs
could you please advise:
1) in Details tab what i should put for "Script Function Call"
2) where to set the selection and whato enter for the "Condition:" Box
3)in properities tab i will select for PROCESSING option: Synchronous. Is this ok?
Thank you in adavnce for your help.[:D]
Posted by:
anonymous_9363
13 years ago
Posted by:
Netrock
13 years ago
Posted by:
anonymous_9363
13 years ago
Posted by:
Netrock
13 years ago
Thank you for your comments. But so far not able to get it work...
the Batch file checks the DNS entry for the PC with the AD server to see if it can resolve the computer name. So if the resolve fails it generate a error message. So, i need to know how i can coporate the batch file into the package.
i am trying different ways but so far nothing. i appreciate if someone can show me what can be done -a clear working way.
Thanks.
the Batch file checks the DNS entry for the PC with the AD server to see if it can resolve the computer name. So if the resolve fails it generate a error message. So, i need to know how i can coporate the batch file into the package.
i am trying different ways but so far nothing. i appreciate if someone can show me what can be done -a clear working way.
Thanks.
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.