EN RU
Log in
Home
Download
Purchase
Documentation
Support
Contact us
 
Help  /  FAQ

How to move and resize dialog controls

You can move and resize the controls of dialog windows. First, you need to know the identifier of the dialog control. You can get it in various ways. For example, you can find it in res\dialogs\*.rc file, or open the file res\dialogs\*.res with any resource editor or special program. Also, you can get the ID of the control with special programs (for instance, Microsoft Spy++) during your installation. For example, the button Next has an ID of 1008 in all dialog windows. See How to get Control ID for more details.

If you want, you can automatically aligned the dialog window contents to the dialog. (except, custom and settings dialogs)
Use the AutoContSize variable.
If the value is 1, the content is resized.
If the value is 2, the size of the bottom buttons (Print, Back, Next, Cancel) is aligned with the width of the window.
If the value is 3, both the content and the buttons will be resized.

How to move the control

Insert the following item into Additional settings.
Variable Name - M:ID where ID is an identifier of the control.
Value - X:Y where X and Y are negative or positive numbers. New left pos = current left pos + X and New top pos = current top pos + Y.

If you want to specify an absolute position then specify the Variable Name as M:ID:A. Also, you can specify a new position as percent of the size of the dialog window.

M:1008 => 10:-50
M:1008:A => 10%:30%

How to resize the control

Insert the following item into Additional settings.
Variable Name - S:ID where ID is an identifier of the control.
Value - X:Y where X and Y are negative or positive numbers. New width = current width + X and New height = current height + Y.

If you want to specify an absolute size then specify the Variable Name as S:ID:A. Also, you can specify a new size as percent of the size of the dialog window.

S:1008 => 30:10
S:1008:A => 20%:30%

How to resize or move dialog window

Insert the following item into Additional settings.
Variable Name - W:S specify 'S' if you want to resize the dialog window, or 'M' if you want to move the dialog window..
Value - X:Y where X and Y are negative or positive numbers. New width = current width + X and New height = current height + Y.

You can specify a new size as percent of the size of the dialog window.

W:S => 0%:15% - increasing the height of the dialog window by 15%.
W:M:A => 0:0 - position the dialog window at the upper left corner of the screen.

The default case you specify the position of the upper left corner of the window. The other 3 sides of the window can also be positioned, in this case, use the W:M:A:LB (left bottom), W:M:A:RT (right top), W:M:A:RB (right bottom) variable names. To specify the center of the window, use the W:M:A:CP (center-point) variable. By default, you have to specify the value in pixels, but you can also specify it in percents relative to the size of the window. To get the screen size, use the System Information command, Screen client area Resolution parameter.

// The upper right corner of the window will be placed at the specified position.
Variable name: W:M:A:RT
Value: 1000:20
// The bottom right corner of the window will be placed at the specified position. (e.g. 
positioning the window at the bottom right corner)
Variable name: W:M:A:RB
Value: #cx#:#cy# //From the Screen client area Resolution parameter

How to disable any control

Insert the following item into Additional settings.
Variable Name - D:ID where ID is an identifier of the control. For example, the Cancel button has an ID of 2 in all dialogs.
Value - 0 specify 0 to disable the control.

D:2 => 0 - Cancel button disabled .

How to hide any control

Insert the following item into Additional settings.
Variable Name - H:ID where ID is an identifier of the control. For example, the Prev button has an ID of 1007 in all dialogs.
Value - 0 specify 0 to hide the control.

H:1007 => 0 - Prev button hidden.

 

See also

  • How to get Control ID
Eonza automation software - free, open source cross-platform program for easy creation and management of scripts.
  • Help
    • Introduction
    • Get to know CreateInstall
    • Compare installers
    • License Agreement
    • License Light
    • License Free
    • Program features
    • Command Reference
    • FAQ
      • Antivirus false positives
      • Command Prompt Mode
      • How to create shortcuts
      • How to get Control ID
      • How to sign an installation
      • How to use environment variables
      • Installing 64-bit applications
      • Local variables
      • Portable version
      • Unpacking filter
      • Common dialog parameters
      • Custom dialog function
      • Global variables
      • How to move and resize controls
      • How to use If Condition
      • Language-dependent variables
      • Multi build setups
      • Predefined folders
      • Predefined variables
      • Variables of dialogs
    • Examples & tips
    • CreateInstall Assistant
    • Problem solving
    • Setup Extractor
Copyright © Novostrim, OOO, 2009-2026 All rights reserved.