Page 1 of 1

Resizing dialog at runtime

Posted: Wed Mar 08, 2006 9:42 am
by Ton_B
When my setup is run in the silend mode, I've coded the script so only the progress dialog is shown to the user. (so the user will know a setup is executed)

I have set the variable SILENT to False and created a new variable SILENTMODE which contains the actual value of the setup-mode.
So, is you use /s the SILENTMODE = True.

Using this method I'm able to prompt users for a reboot and even show a dialog at wish.

Which brings me up to my problem.

Because the setup is run in Silend mode, I do not want the users to see any buttons on the dialog.
I thought the simple way was to reset the dialogs height from 388 to 325.

In the Dialog designer tool, I've placed a invisible label (lblMode) with caption $SILENDMODE$.
I've also created an object rule :

Code: Select all

IF(lblMode.Caption = True) THEN frmWelcome.ClientHeight :=325;
IF(lblMode.Caption = True) THEN frmWelcome.Height :=325;


Unfortunally, the form will still have the heigts set to the default (388).

I thought the size of the form could not be reset, because one (or more) commandbuttons were enabled, in this case the cancel button.
But when I created a object rule to disable and hide all of the command buttons, the form still had it's original heights.

Is it even possible to set the Height of a dialog at runtime ?

Posted: Wed Mar 08, 2006 12:28 pm
by MichaelNesmith
I don't think editing the properties of the dialog itself at runtime is supported.

Posted: Thu Mar 09, 2006 4:10 am
by Ton_B
That is strange.

Creating an Object Rule I get the feeling these properties can be set, bacause they are available in the "Change property" section (see image)

If the properties are read-only they should not be available in the Change Property section, and only be available in the "When Control" section.

Is this a "bug" in IA ?
Can I find a list of control-properties which are NOT read only ?
In that case I can determine which properties I can use and change in run-time.

Image
Image

Posted: Thu Mar 09, 2006 12:45 pm
by MichaelNesmith
Yes, this can be considered a bug in the Object Rules editor, it should not be displaying the frmDesign item as an element with gettable/settable properties. I have reported this to the product team, thank you for bringing this to our attention.