NXKnowledge

Block UI Styler

Block UI Styler

Standard HTML/iframe layout (id="xhtml"), not a PDF — normal extraction technique applies. Small book: Introduction, menu bar commands, Code Generation, Blocks (with Basic/Numbers/Layout/Selection/Special sub-categories), Automation Code, Create a Block Dialog interface, User Defined UI Block.

Note: this complements (does not duplicate) BlockStyler content already extracted into nx-docs-kb\nxopen-prog-guide\ — this book is the *application/tool* documentation (how to use the Block UI Styler GUI itself to build a dialog), whereas the Programmer's Guide content covers using NXOpen.BlockStyler classes from code.

Introduction

Block UI Styler is an application NX users and third-party developers use to interactively build dialog boxes consistent with NX's block-based UI. Key vocabulary:

  • Block — a reusable dialog component (text box, list box, option list, etc.)
  • Group — a frame enclosing related blocks

Benefits per the doc: reduces development time, enables rapid prototyping (visual builder + automatic code generation), builds dialogs to preset NX standards, maintains MenuScript compatibility, and dialogs can be launched from a MenuScript menu bar.

Localization: dialogs can contain localized text, but this requires the end user's OS environment to be set to the correct locale for the desired language.

Menu bar / toolbar commands

Standard dialog-editing operations: New, Open, Save (first save prompts for filename/folder), Cut, Copy, Paste (pastes below the active item), Move Block Up / Move Block Down, Decrease Group Level (and presumably Increase Group Level, cut off in extraction) — i.e. a structural editor for reordering and re-nesting blocks/groups in the dialog tree.

Code Generation

Generates code templates from the Code Generation (Automation) page, in a language you select:

  • C#
  • C++
  • Java
  • VB.NET
  • Python

Also generates comments, entry points, and dialog callbacks. Accessed via: Dialog dialog box → Code Generation tab, inside the Block UI Styler application itself (File tab → All Applications → Block UI Styler in NX).

Blocks (taxonomy)

Left-nav groups blocks into:

  • General Properties — properties common to all blocks
  • Launching dialog from UI component — triggering a Block dialog from a custom UI element
  • Basic — fundamental block types
  • Numbers — numeric input blocks
  • Layout — structural/grouping blocks
  • Selection — NX object-selection blocks
  • Special — miscellaneous/advanced block types
  • Accessing block properties after dialog box closure — reading back values from blocks once the dialog has closed

(Sub-categories weren't individually expanded/transcribed in this pass — each is a javascript:void(0) accordion parent; drill into nx-docs-kb follow-up if full block-type enumeration is needed.)

Automation Code

Chapter covering the generated automation code structure (callback signatures, entry points) — not transcribed in detail this pass.

Create a Block Dialog interface (walkthrough)

Step-by-step tutorial building a tabbed dialog:

  1. Block UI Styler requires an open part in NX.
  2. File tab → All Applications → Block UI Styler.
  3. In the Dialog dialog box, set Type = Dialog, select the Dialog page.
  4. In the Block Id group → Label column, enter a title (e.g. "Tab") — this becomes the dialog's title. Note: the new dialog doesn't visually appear until you place a block inside it.
  5. Under Block Catalog → Selection folder, click Super Section to add a tabbed container; rename its group0 Label (e.g. to "Tab").
  6. Click the Dialog tab in the Blocks area.
  7. Under Block Catalog → Basic folder, click Enumeration to add a dropdown block; rename its enum0 Label (e.g. "Tab Type"). (Walkthrough continues — not fully transcribed.)

Cross-reference: "User Interaction" in the NX Open Programmer's Guide covers how to actually invoke/use a Block Dialog box from NXOpen code once built here.

User Defined UI Block

Chapter title only captured (javascript:void(0) accordion, not expanded) — covers building custom/user-defined block types beyond the stock catalog.

Source: https://docs.sw.siemens.com/en-US/doc/209349590/PL20220512394070742.blockstyler/intro_int_ov_bl · retrieved Tue Jul 07 2026 00:00:00 GMT+0000 (Coordinated Universal Time)