Reference/InstTypeSetText: Difference between revisions

From NSIS Wiki
Jump to navigationJump to search
(Created page with "=InstTypeSetText= inst_type_idx text Sets the Text of the specified InstType. If the Text is empty than the InstType is removed. ...")
 
Line 3: Line 3:
  inst_type_idx text
  inst_type_idx text


Sets the Text of the specified [[Reference/InstType|InstType]]. If the Text is empty than the [[Reference/InstType|InstType]] is removed. By using a previously unused inst_type_idx number you can create new [[Reference/InstType|InstType]]. To add/remove [[Reference/Sections|Sections]] to this new [[Reference/InstType|InstType]] see [[Reference/SectionSetInstTypes|SectionSetInstTypes]]. Unlike [[Reference/SectionIn|SectionIn]] the index is zero based, which means the first install type's index is 0.
Sets the Text of the specified [[Reference/InstType|InstType]]. If the Text is empty than the [[Reference/InstType|InstType]] is removed. By using a previously unused inst_type_idx number you can create new [[Reference/InstType|InstType]]. To add/remove [[Reference/Sections|Section]] to this new [[Reference/InstType|InstType]] see [[Reference/SectionSetInstTypes|SectionSetInstTypes]]. Unlike [[Reference/SectionIn|SectionIn]] the index is zero based, which means the first install type's index is 0.


<highlight-nsis>InstType a
<highlight-nsis>InstType a

Revision as of 10:15, 28 November 2011

InstTypeSetText

inst_type_idx text

Sets the Text of the specified InstType. If the Text is empty than the InstType is removed. By using a previously unused inst_type_idx number you can create new InstType. To add/remove Section to this new InstType see SectionSetInstTypes. Unlike SectionIn the index is zero based, which means the first install type's index is 0.

InstType a
InstType b
 
Function .onInit
  # set first installation type's name to $WINDIR
  InstTypeSetText 0 $WINDIR
  # set second installation type's name to $TEMP
  InstTypeSetText 1 $TEMP
FunctionEnd