We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

h353655
Posts: 47
Joined: Wed Jun 21, 2017 2:51 pm

Replace in string

I needed to persist a parameter, which had no default. This was sadly not possible, but then I set it to default = " " (one space). However, when the user enters stuff in the field, he sometimes forget to remove the space. Is there a way to trim a string?
Attachments
screenshotAI.png
screenshotAI.png (86.85 KiB) Viewed 2746 times
Sorin
Posts: 663
Joined: Mon May 08, 2017 1:03 pm

Re: Replace in string

Hello,

Unfortunately we don't have predefined support for this beahvior. However, you can create you own custom action.

For example, you can create your custom action as a custom action written in C# or a custom action written in C++.


You can also use the VBScript or a PowerShell custom action to implement this functionality.

Please take a look on this article describing how to get/set Windows Installer properties in custom actions : How to set an installer property using custom actions

Best regards,
Sorin
Sorin Stefan - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”