04-28-2011 11:42 AM
Hi,
Does anyone know how to make the table scalable inside a tap control in LabWindow CVI? I see that there is option for a panel to scale contents on resize, but not available for a tab control. Any ideas?
Thanks a lot!
Weiming
Solved! Go to Solution.
04-29-2011 04:25 PM
Hi Weiming,
Have you seen this article on using splitters to resize controls when a panel is resized? You can use splitters in tab controls as well, so you don't need to set any options to do this. So in using the same method that is used for panels in that tip, you can make your table resizable in your tab control.
Hope this helps,
Jen W
Applications Engineer
National Instruments
ni.com/support
05-02-2011 12:49 PM
Hi Jen,
Appreciate your reply, but splitter is not what I am looking for. I want to configure the tab control to automatic scale its contents when the user change the display settings just like a panel can do. For instanse, in Win7, the user can change the display setting to 125% rather than default 100%, and that will mess up the contents on the tab. I couldn't find an easy way to handle it. Please let me know if you know. And I am wondering why LabWindow can't let us configure the tab control just like a panel.
Thanks,
Weiming
05-03-2011 11:03 AM
I'm not sure I understand what you are trying to do, but you can programmatically set ATTR_SCALE_CONTENTS_ON_RESIZE on each tab page panel.
GetPanelHandleFromTabPage(panelHandle, PANEL_TAB, 0, &tabPanel);
SetPanelAttribute(tabPanel, ATTR_SCALE_CONTENTS_ON_RESIZE, 1);
05-04-2011 07:06 PM
Thanks for your help! I also found out that as long the parent panel set to Scale Contents On Resize, this attribute will automatic pass to any child panel or tab inside it.
08-09-2011 04:30 AM
Hi Jen ,
I am using LV2009, and cannot use splitters in tab controls.
Am I missing something, or is this feature only LV2010&up?
http://forums.ni.com/t5/LabVIEW/splitter-in-tab-control/td-p/1458654
08-09-2011 04:36 AM
Hi SGIE,
you have posted a LV-related question to the LabWindows/CVI forum: you should post it in the LabVIEW forum instead.