Creating a Non-Modal User Dialog Box

DIAdem 2018 Help


Edition Date: June 2018
Part Number: 370858P-01
View Product Info

DOWNLOAD (Windows Only)


DIAdem 2015 Help
DIAdem 2017 Help
DIAdem 2018 Help
DIAdem 2019 Help
DIAdem 2020 Help

Use non-modal user dialog boxes when you want to request and to display information in a dialog box but want to keep the focus on a different dialog box or a different window.

To create a non-modal user dialog box, complete the following steps:

  1. Select the DIAdem SCRIPT panel.

  2. Select Edit»Create Dialog Box.

  3. Use the properties window to specify the size of the dialog box.

  4. Click the column to the right of the Height field on the Properties tab. Enter 50 as the height.

  5. Click the column to the right of the Width field on the Properties tab. Enter 130 as the width.

  6. Click the Text control on the Controls bar.

  7. Drag open the control in the dialog box.

  8. Enter the text Non-modal dialog box.

  9. Select File»Save As and save the file as Test.sud.

  10. Close the dialog editor and switch to DIAdem.

  11. Select File»New»VBS Script to create a new script.

  12. Enter or copy the following text into the script editor:

    Dim MyDlg, Ipos, Hor, Ver
    Set MyDlg = SudDlgCreate("Dlg1","Test.sud")      ' Creates dialog object
    
    iPos=AppRectangleGet(1)                          ' Returns free area below the panel bar
    
    Hor = MyDlg.MapXPixelToDlu(iPos(0)) - MyDlg.Left ' Calculates into dialog units
    Ver = MyDlg.MapYPixelToDlu(iPos(1)) - MyDlg.Top
    Call MyDlg.Move(Hor, Ver)                        ' Moves dialog into free area
    
    MyDlg.Show                                       ' Shows dialog
    MyDlg.Activate                                   ' Activates dialog
  13. Select Script»Run VBS Script to start the script.

The non-modal user dialog box appears at the bottom left on the screen. The user dialog box remains open even when you select a different panel, for example, DIAdem ANALYSIS, and if you execute a function in this panel, for example, smoothing the second channel.

  1. Close the user dialog box.

Examples

Analyzing and Displaying Channels Section by Section | Checking Dialog Box Entries | Dynamic User Dialog Box | Translating User Dialog Boxes | User Dialog Box for Entering Text and Numbers | User Dialog Box for Sequence Control | User Dialog Box in DIAdem VIEW | User Dialog Box in VIEW for the Calculation of the FFT and Harmonic Frequencies | User Dialog Box with Changing Background Color | User Dialog Box with Curve Preview | User Dialog Box with Extended Table | User Dialog Box with Internet Explorer | User Dialog Box with Scalable Table | User Dialog Box with Selection Lists | User Dialog Box with Selection Lists | User Dialog Box with Subdialog Boxes | User Dialog Box with Tables | User Dialog Box with Tree | Wizard for Tolerance Evaluation

WAS THIS ARTICLE HELPFUL?

Not Helpful