How to implement the style of Preference Dialog of LabVIEW 8.2?
#1
Posted 30 November 2006 - 03:04 PM
In the directory of resource\dialog\PreferencesDialog you can find the PreferenceDialog.vi, the UI looks like the image as below:
and in the directory of \resource\dialog\PreferencesDialog\PreferencePages you can find all PreferenceDialog pages, such like prefPage_BlockDiagram.vi look like the image as below:
so I guess the PreferenceDialog.vi embodied the page Vis User Interface,When user select one item, the PreferenceDialog.vi embody the selected page vi realtime, and I think this may be implement by subPanel, But I can't realize it. Any one know the secret of PreferenceDialog? thanks a lot?
By the way, this is one way to implement plugins archetecture?
#2
Posted 30 November 2006 - 04:04 PM
you'll probably be able to figure out how the dialog works from that. it has this comment in the "PanelClose?" event case:
"This is useful during development,
so you can run your page VI without
the dialog framework.
When running in the frame VI's subpanel,
you should never get a panel close event."
so I guess the PreferenceDialog.vi embodied the page Vis User Interface,When user select one item, the PreferenceDialog.vi embody the selected page vi realtime, and I think this may be implement by subPanel, But I can't realize it. Any one know the secret of PreferenceDialog? thanks a lot?
By the way, this is one way to implement plugins archetecture?
#3
Posted 30 November 2006 - 06:34 PM
In the same directory, there's also a template to build your own pages (i guess), called pageTemplate.vit with an unlocked diagram. it's window title is "Use VI Window Title as Category Name"
![]()
you'll probably be able to figure out how the dialog works from that. it has this comment in the "PanelClose?" event case:
"This is useful during development,
so you can run your page VI without
the dialog framework.
This is very nice of NI, I think they did this on purpose (really). I haven't looked at it yet but it sound very promising!
:thumbup: :thumbup:
Ton
#4
Posted 01 December 2006 - 02:57 PM
Yes, it seems to be realized with subPanel.I think this may be implement by subPanel, But I can't realize it.
Probably attached "quick and dirty" VIs will be helpful for you?
Download File:post-1163-1164984963.zip
best regards,
Andy
#5
Posted 01 December 2006 - 03:23 PM















