• Status: Solved
  • Priority: High
  • Security: Public
  • Views: 63
  • Last Modified:

Replacing / Amending files within installation .EXE


We have an installer file for our AV software which we want to roll out, however, there are a couple of XML files within the installer that need to be amended in advance of installation.

Has anyone got any thoughts about how we can inject the revised XML files into the current installation package?


1 Solution
Hopefully I haven't got the wrong end of the stick here, but if not then welcome to the world of application packaging: the requirement to tailor a vendor's installation of an application in order to customise it for a specific setup in an organisation.

When an application has a fully compressed .exe as its setup program, it usually means that it self-extracts and executes an installer program.  There are as many types as you can imagine.  And some of those types can be manipulated, for example if the .exe has an internal .msi as its installer, you can with the skills and software, create an .mst transform to deliver anything you want too, for example 2 x XML files.

But it sounds like you are not familiar with application packaging, so I think the quickest and simplest way for you to deploy this is with a basic application install wrapper.

Step 1: Create a folder.  This is your deployment package.  Copy into it your AV Setup .exe.
Step 2: Copy in the 2 x new XML files into the new folder too.
Step 3. Create a batch file, something like this:

Set CURRDIR=%~dp0   {NOTE this will set %CURRDIR% to folder that the batch file is in including the trailing backslash}
REM Install AV Software
"%CURRDIR%AVSoftInstall.exe" /silent {or whatever the unattended commandline is for this}

REM Copy new XML
Copy "%CURRDIR%newxml1.xml" "C:\Program Files\AVSoft\anotherfolder\"
Copy "%CURRDIR%newxml2.xml" "C:\Program Files\AVSoft\anotherfolder\"

Open in new window

Then your installation process is to deploy the folder, then execute the batch file.

You could even then create a new self-extracting exe that contains the new package folder and executes the batch file.

Good luck!

FriendlyITAuthor Commented:
Really helpful!  In this instance the manufacturer have actually changed the package, but this is really helpful information for the future.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: Amazon Web Services - Basic

Are you thinking about creating an Amazon Web Services account for your business? Not sure where to start? In this course you’ll get an overview of the history of AWS and take a tour of their user interface.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now