When I specify a readme file, the first check box on the final page is automatically created to allow the user to view the file (or not). If it is left checked and there are other check boxes for additional actions, these actions don't get executed until after the Readme File Viewer is exited. Is there a way to 1) launch the Readme File Viewer in the background or 2) change the position of the "View Readme File" check box so that it is not the first check box

asked 15 Oct '12, 10:30

DennisU's gravatar image

DennisU
16779
accept rate: 0%


It is not possible to configure it for <readmeFile>.

What can be done is ship the README file as part of installed files, instead of <readmeFile> option and then add a <showText> action as last option:

<finalPageActionList> <!-- ... --> <!-- read the README file, setting show to 0 prevents it from being shown as an option --> <readFile> <name>readme_contents</name> <path>${installdir}/README.txt</path> <show>0</show> </readFile> <!-- add option to show the README file --> <showText> <progressText>Show readme file</progressText> <text>${readme_contents}</text> <title>Readme</title> </showText> </finalPageActionList>

The action still runs in the foreground and it cannot be run in the background (i.e. as a child process). However, this will work fine if the checkbutton is shown as last entry.

If you want to show the checkbutton before other entries, but still run the <showText> at the end, you can simply have a visible action that sets a variable and then a hidden <showText> action at the end that is only run if the visible checkbutton was selected. For example:

<finalPageActionList> <!-- the actual checkbutton that is shown to the user --> <setInstallerVariable> <name>show_readme_file</name> <progressText>Show readme file</progressText> <value>1</value> </setInstallerVariable> <!-- ... --> <!-- read the README file, setting show to 0 prevents it from being shown as an option --> <readFile> <name>readme_contents</name> <path>${installdir}/README.txt</path> <show>0</show> <ruleList> <isTrue> <value>${show_readme_file}</value> </isTrue> </ruleList> </readFile> <!-- add option to show the README file --> <showText> <progressText>Show readme file</progressText> <text>${readme_contents}</text> <title>Readme</title> <show>0</show> <ruleList> <isTrue> <value>${show_readme_file}</value> </isTrue> </ruleList> </showText> </finalPageActionList>

This way the action is always run last and only if the user has selected the Show readme file checkbutton.

link

answered 15 Oct '12, 10:35

wojciechka's gravatar image

wojciechka ♦♦
7.8k61122
accept rate: 26%

Well this solution lets me reposition the check box, but the viewer "show text" dialog still runs in the foreground and blocks any actions that follow it in the list. Can I make it run in the background?

(15 Oct '12, 18:13) DennisU

I have added another solution to this issue in the answer above - basically by adding an action that is associated with a checkbutton and another action that is run at the end and does not have a checkbutton.

(16 Oct '12, 03:44) wojciechka ♦♦
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×12
×7
×4

Asked: 15 Oct '12, 10:30

Seen: 2,946 times

Last updated: 16 Oct '12, 03:44