Start a program with changing names

Ask general questions here.
Christoph
Posts: 23
Joined: Wed Jul 11, 2012 6:22 am
Location: Liechtenstein

Start a program with changing names

Post by Christoph » Wed Jul 11, 2012 10:13 am

Hi,

How can I start a program which changing names?

This is what I'd like to to:
My system under test is an msi installation file. (actually there are a number of them) I'd like to start the installation with Ranorex and monitor the process. The msi file gets created by the build server. The filename includes the version of the program as well as the build number. This means that after every build the msi has a different name. For example: after build 1 the msi is called "myProg_v01.01.01_build_01.msi. After the second build it is called myProg_v01.01.01_build_02 etc. In addition to that the version number could also change. So the only fix part in the filename would be "myProg_".

I need to mention that in the folder with the msi there are a number of msi files with different fixed parts, but from only one build. So the folder may look like this:
- myFirstProg_v10.4.23_build_25.msi
- mySecondProg_v2.5.564_build_25.msi
- myThirdProg_v0.0.56_build_25.msi

Before the msi from a new build are placed in the folder the existing msi would get deleted. So there are only msi in the folder from one build.

So how can I tell Ranorex to start the msi by giving only the fixed part of the name? i.e. start program "mySecondProg_v2.5.564_build_25.msi" by spezifiing only "mySecondProg"

Christoph

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: Start a program with changing names

Post by Support Team » Thu Jul 12, 2012 2:21 pm

Hi Christoph,

How do you start the specific msi file?
Are you working with user code or with recorded actions only?
Did you try to use regular expressions?

Regards,
Markus
Ranorex Support Team

Christoph
Posts: 23
Joined: Wed Jul 11, 2012 6:22 am
Location: Liechtenstein

Re: Start a program with changing names

Post by Christoph » Fri Jul 13, 2012 6:18 am

Hi Markus,

Thanks for your response.

So far I launched the msi from a recorded action. (I added the action manually). Meanwhile I found out how to make code from this so using regular expressions then would not be too difficult. I was shying away a bit from writing code, if possible, but I already needed some code to check, if the progam is already installed and if yes uninstall ist first, before starting the msi. So I'm already into the code so I guess I will pursue this route also for lanching the msi with changing names.

Christoph