cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
RayKode
Level 6

Custom Action New EXE

Afternoon,

I was wondering if I might ask for some opinions as to how I might implement a New EXE custom action.

Here's what my command line looks like, if I were to run it, from the command line.

C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Caspol.exe -lg > C:\Caspol.txt

I "think" the CA is launching the executable, because I "see" a dos box pop up momentarily.
And I see what I "think", is the output of Caspol.exe.

But I can't seem to figure out how to code the redirection part.
I want to redirect the output of Caspol.exe -lg, into a .txt file somewhere, so that I might open it later and search it for a string.

I've tried a number on constructs on the command line of the New EXE custom action.
But I haven't been able to figure out the correct way of redirecting the output to a text file.

Has anyone been successful in redirecting output via the Executable custom action ?

If so, might I ask for a pointer or perhaps an example ?

Thanks you so much.
Labels (1)
0 Kudos
(2) Replies
RayKode
Level 6

David, from Installshield suggested the following, which worked perfectly.

Choose "New EXE (With a path referencing a directory)
Working directory:
0 Kudos
Christopher_Pai
Level 16

I'd look at the Quiet Execution Custom Action found in WiX. It will make your flashing dos box go away, redirect the stderr and stdout to the windows installer log and mitigate a bunch of other risks that aren't obvious upon first glance.

It's just a type 1 DLL custom action so it's really easy to integrate with InstallShield based MSI's.
0 Kudos