I am using Install Script in Install Shield 2013 on Windows 7, Lang Used C#.
I have a project and it has some features and sub features added to it. Now I want to build a new release using Automation Interface need to add some selective features/ subfeatures to this release so that the original features remains unaltered.
We can pass the New release name and features required in this release using Command Line.
How can I add selective features supplied as command line arguments to my release. Is there any predefined Object/function/Method for this. Please advise.
Need to achieve this in Install Script only.
How can I add some selective features/ subfeatures to a new release bu
Posted 27 January 2015 - 12:05
Posted 28 January 2015 - 12:57
Maybe I'm misunderstanding your question, but is FeatureSelectItem what you are looking for?
Stefan Krüger
InstallSite.org twitter facebook
Posted 29 January 2015 - 05:27
Hi Stefan,
Thanks for the reply.
I guess FeatureSelectItem is called during we are installing the setup. Am I right?
I need a function which I can call during the build of the release through the Automation Interface. I have a script in C# through which I want to call a function of ISWiProject or ISWiFeature( or any such object...) with which I can select the features that I want to include in my this particular Release build.
I need a property something like IncludeInBuild. The problem with IncludeInBuild is that it alters the default behaviour of the Feature. I just want a similar property with which I can Select the features for a paricular new Relaease build only and default behaviour is not altered. Need to do the work in attched screen shot in Release Wizard through Scripting.
Need to do so to minimise the size of my installation setups.
Hope this time I was able to explain my Query.
Awaiting your response.
Edited by Sukrit, 29 January 2015 - 05:51.
Posted 29 January 2015 - 19:09
How does IncludeInBuild change the behaviour of the feature? If you set it to false, it won't be included in the build, so it shouldn't matter. And if you don't call IncludeInBuild for a feature (and it's included by default) there also shouldn't be a problem. Maybe I'm still misunderstanding you, sorry.
Stefan Krüger
InstallSite.org twitter facebook
Posted 02 February 2015 - 09:24
Let me try to explaoin it with the help of an example:
Let us suppose we have two features and their default includeinBuild is as follows:
Feature IncludeInBuild
Feature1 Yes.
Feature2 No.
Now I want to build a new release using Automation Interface (Script in C#) without Using Any GUI of IS.
Let Say I want to include Only Feature2 in this release. So, If I use IncludeInBuild I'll Do:
feature1.IncludeInBuild = false;
feature2.IncludeInBuild = true;
Now I'll Run build() and a release will be made.
Now next time when I again want to build a new release with the default features which were earlier set like below:
Feature IncludeInBuild
Feature1 Yes.
Feature2 No.
I call the build() , but the features included are :
Feature1 No
Feature2 Yes
because we have changed the includeinbuild property.
So I want to know is there any predefined alternate property with whose help I can achieve required functionality i.e. with which we can build a release without affecting the default IncludeInBuild of Feature.
I know that an alt way of achieving so is that I can Store the Current state of IncludeInBuild oif feature before altering them, then alter them, build release and then re apply the state from thye stored state.
But I am looking forward If I can get a direct inbuilt function for achieving so.
Hope now I am Clear. Please advise. Thanks in Advance.
Posted 03 February 2015 - 15:45
Now I understand. So the problem si that the change is stroed in the project file.
I'm not aware of a method to temporarily chage this in an InstallScript project. So the best workaround may be to make a copy of the project file.
Stefan Krüger
InstallSite.org twitter facebook