LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How do you get an easytab panel ID ?

I am using a GetCtrlVal on a easytab panel how do I find out the panel ID, it's not listed in my header file. I loaded the panel into memmory at the start of main but the panelhandel ID is a completly different to what I get if I look at the panel ID No generated from a callback of that panel.
0 Kudos
Message 1 of 2
(3,126 Views)
First, understand that there are two numbers associated with a panel. The panel constant (#defined in the header file and used as the resource identifier), and the panel handle (returned from LoadPanel or EasyTab_LoadPanels and used to refer to a currently loaded panel). The panel handle is what is used to refer to the panel after it is loaded. The panel constant in the header is just used to load the panel from the UIR resource file.

There are two ways to load panels into easy tabs.

1) Load the panels with LoadPanel, then Add them to an EasyTab control with EasyTab_AddPanels. In this case, the panel handles are given to you for each panel from the LoadPanel calls.

2) Combine the LoadPanel calls with adding them to an EasyTab control with the EasyTab_LoadPa
nels. In this case, each panel handle is returned to you in the EasyTab_LoadPanels call. For example,

EasyTab_LoadPanels(parentPanel, tabCtrl, row, "sample.uir",
__CVIUserHInst, PANEL_1, &panel1, PANEL_2, 0,
PANEL_3, &panel3, 0);

The variables panel1, panel2, and panel3 are the panel handles for the loaded panels with panel constants PANEL_1, PANEL_2, and PANEL_3.

See the EasyTab_LoadPanels FP help for more discussion on this.

Best Regards,

Chris Matthews
Measurement Studio Support Manager
0 Kudos
Message 2 of 2
(3,126 Views)