09-29-2011 10:17 AM
I call EasyTab_SetAttribute (Panel, TabCtrl, ATTR_EASY_TAB_ACTIVE_PANEL, ScnPanel) to set an active tab panel. The panel is displayed with the tab label highilighted. When I call SetActiveCtrl (ScnPanel,control) the control does not become active, although the function returns successful (0). The tab label is still highlghted. When I try to use the mouse to select any entry box in the panel, they do not become active, and I can not enter any data. However, checkboxes and pull downs work. The TAB key also works to move the highlight/active control. In fact, once I move the highlight of the tab label to a control, the mouse works.
Thanks for yout help.
09-29-2011 03:51 PM
This is definitely a strange behaviour: the EasyTab control is included in CVI from its release 4: it's a mature instrument fully debugged and I never observed a similar behaviour when using it. Can you reproduce this behaviour in a small sample project and post it here so that we can look at it and try to understand what's happening?
Besides it, with newer versions of CVI (I seem to remember from CVI8 on) a native tab control has been introduced: if you are using one of these versions you could plan to move to native tab control instead of using EasyTab.
04-23-2015 02:53 PM
I realize this thread is almost 4 years old, but I came across the same problem today. I wanted to provide a solution for it.
To work-around the problem with the active control and Easy Tabs, you must call SetActivePanel before SetActiveCtrl. In your case, it is:
SetActivePanel (ScnPanel);
SetActiveCtrl (ScnPanel,control);
04-24-2015 03:12 AM
Hello LoKK,
thanks for giving your solution.
Nevertheless, unless you are developing on a version of CVI prior to 8 I strongly recommend you to move your code to the built-in tab control which supersedes EasyTab instrument.
Having integrated the tab control in native UI controls makes it less likely that EasyTab is maintained over time: you can see that the instrument has not been updated since 2012 and additionally it cannot be run in 64-bit code so it is a good option taking some time to practice with the native control and your code to it, which is not so difficult.