LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

GUI Problem - Combining indicator and control tables with buttons - Modbus

Hello,

First of all, due to work ethics / confidentiality, I unfortunately cannot share my project files.

I am working on a LabVIEW (2025 Q3) application for communication via Modbus. My application creates Modbus requests for holding registers, both read and write. The data read from the device is displayed in a table.

UMT_UI2.jpg

 

In the front panel screenshot, the current layout is marked as follows:

[1] Main table with read values and tag information
[2] Separate "NewValue" table where the user enters the value to be written
[3] Separate "Write" buttons used to confirm writing the value for a given row

If a tag / row / register has its access type defined as RW (ReadWrite), user can change its value by entering a new value in the corresponding row of the NewValue table and then pressing the Write button on the same row.

 

Quick note: Keeping all the data as holding registers is intentional, because it minimizes the number of requests needed to get all the information from the device. I know that input registers exist. 🙂

 

The current solution works, but it does not look very professional. I also have problems keeping these three UI elements aligned with each other. After building the application, the table, NewValue column, and the buttons are sometimes slightly misaligned or have different sizes.

Ideally, I would like to have the editable cells and the write buttons directly inside the main table, next to the corresponding read values. However, UI design and programmatically modifying UI elements are not my strongest areas, so I would appreciate suggestions.

 

What would be a cleaner and safer way to implement this kind of UI in LabVIEW?

 

I have also attached a simplified block diagram screenshot showing how the current write logic works:

  • The write buttons are stored as a cluster / array of Boolean values.
  • I search for the pressed button.

  • I use the index of the pressed button to select the corresponding value from the NewValue array.

  • I use the same index to select the corresponding row from the main tag table.

  • These values are then used to create the Modbus write request.

Any suggestions regarding a better UI architecture or a more robust implementation would be appreciated.

 

J_Pommelec_1-1783083058893.png

 

 

J_Pommelec_0-1783082256703.png

 

0 Kudos
Message 1 of 2
(115 Views)

I would not have the write column or the write button. Instead I would handle a click or a double click event on the table row and use that to pop up and 'edit dialog' Which would populate with the value from that row and that the user either edit it and submit it or cancel. This way anything else on the table you want to add it can be handled using the same method rather than typing directly into the table control or list. You can either have the pop-up centred on the screen or get the coordinates of the cell that was clicked and show the box at that row.

0 Kudos
Message 2 of 2
(58 Views)