cvas
Posts: 43
Joined: Mon Oct 01, 2007 8:20 pm

Set PUBLIC property to Private Property

how i can Set PUBLIC property to a Private Property ?
i had one search public property "SEARCH_FILE" and i want to set the value of this property
to a private "Search_File" property how i can do that ?
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: Set PUBLIC property to Private Property

Hello,

You can add a "SetProperty" published event on one of the controls from your installation chain. However please keep in mind that the InstallUISequence will be skipped when installing silently, hence this operation will not occur.

If this private property is defined in the InstallExecuteSequence, you can use a "Property Set with Formatted" custom action or set it from within your own.

All the best,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
cvas
Posts: 43
Joined: Mon Oct 01, 2007 8:20 pm

Re: Set PUBLIC property to Private Property

i do it and a make the build and works .
but when i open the AI again and load the project the AI rename again the Public Property to xxxx_1
Bogdan
Posts: 2791
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Set PUBLIC property to Private Property

Hi,

I'm not sure why this happens. Can you please send us the two versions of the aip file, before and after the property is renamed, to support at advancedinstaller dot com so
we can analyze them?

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: Set PUBLIC property to Private Property

Hi,

This happens because you are using an extended search. Extended searches need to use unique property names. "OLD_VER_SEARCH" property is already initialized by your SetProperty control event. So when the prerequisite search is loaded an unique name is generated for it.

A solution is to use a normal file search instead of an extended one:
http://www.advancedinstaller.com/user-guide/search.html
http://www.advancedinstaller.com/user-g ... rties.html

Another solution is to use OLD_VER_SEARCH property directly. I'm not sure why you are saving it in a private property.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
KhalifaaSheikh
Posts: 1
Joined: Wed Aug 08, 2018 11:56 am

Re: Set PUBLIC property to Private Property

Hi Cosmin,
Thanks for forward us to the right place, i also have this issue about search..
Daniel
Posts: 8238
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Set PUBLIC property to Private Property

You are always welcome.

We are glad this thread was useful for you.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”