LS,

I'm using Wise 4.62. I'm using a system search to get an install location. The only problem is, that I have to go 1 folder above the result of the search. Example:
The result of the search is c:\progam files\Microsoft\Office_02\Office10 and I need the make that c:\progam files\Microsoft\Office_02. How do I do this?

Thanks in advance.
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Answers

0
[8D]

My idea would be to have a Custom Action that retrieves the property into a string variable and then modifies it.

Once modified, the CA would then set the property to the new value.

[8D] Keep cool. [8D]

Need to know the script etc???
Answered 02/09/2005 by: brenthunter2005
Fifth Degree Brown Belt

Please log in to comment
0
ORIGINAL: brenthunter2005

[8D]

Need to know the script etc???



If that would be possible? That would be great.

tnks.
Answered 02/09/2005 by: call2
Senior Yellow Belt

Please log in to comment
0
[8D]

OK, this CA is in VBScript (so ensure your target computers have WSH installed etc)

strPROPERTY = Session.Property("YOUR_PROPERTY_IN_THE_PROPERTY_TABLE") 'Get your property from the Property table in the MSI.

strNEWPROPERTY = Left(strPROPERTY,InStrRev(strPROPERTY, "\") -1) 'Modify the string

Session.Property("strPROPERTY") = strNEWPROPERTY 'Put the string back into the property table


The sequence location of this CA would be best suited after the AppSearch action.

I hope this makes sense and helps.

[8D] Keep cool. [8D]
Answered 02/09/2005 by: brenthunter2005
Fifth Degree Brown Belt

Please log in to comment
0
Tanks,

That realy helped me out. [:D]
Answered 02/09/2005 by: call2
Senior Yellow Belt

Please log in to comment
0
[8D]

No probs!

[8D]
Answered 02/09/2005 by: brenthunter2005
Fifth Degree Brown Belt

Please log in to comment
0
hmmm.....I can't get it to change the result of the appsearch.

Btw, I'm a moron with VB, so I'm probably doing something wrong. Here's what I do:

strPROPERTY = Session.Property("APPZOEKEN")
strNEWPROPERTY = Left(strPROPERTY,InStrRev(strPROPERTY, "\") -1)
Session.Property("StrPROPERTY") = strNEWPROPERTY
Answered 02/09/2005 by: call2
Senior Yellow Belt

Please log in to comment
0
[8D]

Entries in the PROPERTY table are case-sensitive.

Whoops! I f**ked up in my code. <Note to self - double check my work!>

Your third line of code should be:

Session.Property("APPZOEKEN") = strNEWPROPERTY
Answered 02/09/2005 by: brenthunter2005
Fifth Degree Brown Belt

Please log in to comment
0
ORIGINAL: brenthunter2005

[8D]

Entries in the PROPERTY table are case-sensitive.

Whoops! I f**ked up in my code. <Note to self - double check my work!>

Your third line of code should be:

Session.Property("APPZOEKEN") = strNEWPROPERTY


I know, thats why I always use capitals for Properties I add myself.

I'm gonna try your correction.

The result of this code gos back into the same property? Right? I'm not sure.
Answered 02/09/2005 by: call2
Senior Yellow Belt

Please log in to comment
0
Yeah, its basically just updating the property 'APPZOEKEN' with the new value you want.
Answered 02/09/2005 by: brenthunter2005
Fifth Degree Brown Belt

Please log in to comment
0
ORIGINAL: brenthunter2005

Yeah, its basically just updating the property 'APPZOEKEN' with the new value you want.

Oke, thats what I Thought.

It's not working right now, and I don't know what I'm doing wrong, but I'll keep trying.

I'm going home now, so if I don't succed, I gonna post tomorrow.

Thanks for all the help sofar!
Answered 02/09/2005 by: call2
Senior Yellow Belt

Please log in to comment
0
[8D]

Ensure that the CA is running AFTER the 'AppSearch' action within the 'InstallExecuteSequence' table.


Also, you can add the MSGBOX function within the VBScript to display the string values during runtime. I kind of debugging option if you will...

[8D]
Answered 02/09/2005 by: brenthunter2005
Fifth Degree Brown Belt

Please log in to comment
0
It still won't work.

This is my InstallExecuteSequence table (just the AppSearch and my action)


AppSearch | NOT OEM_NOPREVIOUS | 100
APPZOEKENRES | NOT Installed | 101

So, It is after the AppSearch. I've displayed the value of APPZOEKEN in the dialogs of the MSI, and he doesn't change at any time. I've tried the MSGBOX but he doesn't show.

I tought I might have forgotten to install the VBR but I checked that, and I have insalled that so, I realy don't know what I'm doing wrong.

(I use the "Call VBScript From Embedded Code" function in Wise)
Answered 02/10/2005 by: call2
Senior Yellow Belt

Please log in to comment
0
Hello call2

If the MSGBOX function in the CA isn't displaying a dialog box or anything, I think you have a bigger problem like the CA not running at all!
Answered 02/10/2005 by: brenthunter2005
Fifth Degree Brown Belt

Please log in to comment
0
Any ideas what could be wrong?
Answered 02/10/2005 by: call2
Senior Yellow Belt

Please log in to comment
0
[8D] OK, a few things:

1. What OS are you deploying to?
2. Ensure that Windows Scripting Host (WSH) is installed. To test this, drop to the CMD prompt and type in cscript.exe.
3. Try removing the conditions from both of the actions.
4. If you are using WISE you can use 'debug' option and run through the MSI package ensuring that the custom actions are running.
5. As above, but logging the MSI installation using the command line: msiexec /I package.msi /l*v c:\temp\MSI_LOG.txt


Good luck!
Answered 02/10/2005 by: brenthunter2005
Fifth Degree Brown Belt

Please log in to comment
0
Oke, thanks

It's working now! [:)]

Thanks for all the help!!
Answered 02/10/2005 by: call2
Senior Yellow Belt

Please log in to comment
-1
What did you have to do to get it working?
Answered 02/10/2005 by: brenthunter2005
Fifth Degree Brown Belt

Please log in to comment
0
Thanks too, I think it will help me a lot ! :-)
Answered 07/22/2005 by: babric
Senior Purple Belt

Please log in to comment
Answer this question or Comment on this question for clarity