Search found 9 matches

Go to advanced search

by och
Tue Feb 17, 2015 2:07 pm
Forum: Building Installers
Topic: Pass Property with spaces to Powershell script
Replies: 3
Views: 7828
 
Jump to post

Re: Pass Property with spaces to Powershell script

It somehow works.

The path is full now but there are trailing quotes at the and so it looks like this C:\Program Files\Manufacturer\Product Name"
I remove it with this line

Code: Select all

$appDir = $appDir -replace '"',''
but I don't understand why it is happening.
by och
Thu Feb 12, 2015 11:41 am
Forum: Building Installers
Topic: Pass Property with spaces to Powershell script
Replies: 3
Views: 7828
 
Jump to post

Pass Property with spaces to Powershell script

Hi,

how can I pass Windows Installer Property which contains spaces to Powershell script Custom Action? I want to read APPDIR in script but string is terminated after first space.
In Script Parameters I have

-appDir [APPDIR]

and in script I am checking it

param($appDir)
echo $appDir >> "C ...
by och
Wed Feb 11, 2015 4:55 pm
Forum: Building Installers
Topic: Pass Windows Installer Property to Powershell script
Replies: 6
Views: 7353
 
Jump to post

Re: Pass Windows Installer Property to Powershell script

I got response from support and they helped me to solve it.

The problem was that the param($appDir) must be the first line in the script. So I changed from

date >> "C:\install.log"
param($appDir)
echo "appDir 1" >> "C:\install.log"
echo $appDir >> "C:\install.log"
echo "appDir 2" >> "C:\install ...
by och
Wed Feb 11, 2015 1:10 pm
Forum: Building Installers
Topic: Pass Windows Installer Property to Powershell script
Replies: 6
Views: 7353
 
Jump to post

Re: Pass Windows Installer Property to Powershell script

Ok, I have sent it. Hope it'll help.
by och
Tue Feb 10, 2015 2:29 pm
Forum: Building Installers
Topic: Pass Windows Installer Property to Powershell script
Replies: 6
Views: 7353
 
Jump to post

Pass Windows Installer Property to Powershell script

Hi,

I want to pass Windows Installer Property (APPDIR) to Powershell script Custom Action. I checked http://www.advancedinstaller.com/user-guide/custom-actions-list.html#powershell-script but it doesn't work for me. Or maybe I am using it wrong.
In my "Script Parameters" input box i filled
-appDir ...
by och
Thu Jan 08, 2015 11:49 am
Forum: Building Installers
Topic: Searched numeric registry raw value prepended with #
Replies: 5
Views: 7020
 
Jump to post

Re: Searched numeric registry raw value prepended with #

Yes! That's it, thanks very much!
by och
Wed Jan 07, 2015 4:33 pm
Forum: Building Installers
Topic: Searched numeric registry raw value prepended with #
Replies: 5
Views: 7020
 
Jump to post

Re: Searched numeric registry raw value prepended with #

Thank for reply,
but I'll need some more information.

I found Custom Action "Set Installer Property" which seems the most appropriate. But how do I do the actual character removal? All I found is http://www.advancedinstaller.com/user-guide/formatted.html and http://www.advancedinstaller.com/user ...
by och
Wed Jan 07, 2015 1:03 pm
Forum: Building Installers
Topic: Searched numeric registry raw value prepended with #
Replies: 5
Views: 7020
 
Jump to post

Searched numeric registry raw value prepended with #

Hello,

I am trying to search for numeric value in registry and then use it in different registry key. The value is of type REG_DWORD. But the result is prepended with # character.

Example:
I search for
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\Common]
"LastAccessInstall"=dword:0000000e ...

Go to advanced search