Here is a simple but useful macro you can add to your Macro.xml file found in the Active 4D folders on both Windows and Mac. The macro generates code that can be used to open a plain centered dialog form window. Simply cut and paste the following macro fragment in between the <macros> ... </macros> tags.
$windowRef:=Open form window(<selection/>;Plain window;Horizontally centered;Vertically centered)
To test it out, write and highlight the following code in the method editor:
Call the macro OpenDialog and the macro will automatically write out the code necessary to open the dialog window.
After the macro call, you'll have the following:
$windowRef:=Open form window([Table 1];"Form1";Plain window;Horizontally Centered;Vertically Centered)