From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
12-21-2011 04:57 PM
I'd like to the add the Forward/Back Buttons to my User Interface similar to those in the Sequence Editor. I use a modified version of the Full Featured UI on the production floor and often switch to editor mode to work on the sequence. I find it very cumbersome not to be able to jump back and forth between Sequences while doing so.
Were the buttons created using the "Editing Class" proporties and methods to build a stack of recently selected sequences? Or are the buttons already existing with the methods simply needed to be called?
Any suggestions how to impment this functionality while in edit mode?
Thanks
12-22-2011 04:17 PM
The Full Featured UI is the best one to use, but keep in mind that the UI is not meant for developing. It instead was designed with operators debugging in mind.
After examining the NI Teststand User Interface Controls document and the Full Featured UI, it looks like you actually cannot reference the toolbar, let alone the forward and back buttons from the toolbar. The toolbar is only referenced under the ReportView, meaning that you can only access the Report toolbar.
12-22-2011 04:46 PM
"but keep in mind that the UI is not meant for developing. It instead was designed with operators debugging in mind."
I don't agree with that. The UIs are fine for developing if they meets your needs. If not, then you have to weigh using the sequence editor, which is not nearly as customizable, vs the cost of reimplementing whatever you can't do without that the sequence editor already has.
Note that most of the things that are missing from the UIs would take a fair amount of effort to re-implement (type editing, ...). If there were already simple-user-ready-drop-in-components for the missing features, we probably would have already included them in the UIs.
We want the UIs to be functional, but the top priority is that they be simple enough such that they can be readily modified.
Note that in some cases there are apis to support features that aren't in the UIs, but there isn't a complete control that wraps everything. For example, Engine.SearchFiles() is a huge amount of the implementation for find-and-replace, but there currently isn't a user callable dialog for invoking it or a user accessible control for automatically browsing the results, thus we don't currently include that feature in example code for the UIs. I don't know the specifics of forward/back, so I'm not sure how much of the implementation is exposed as public APIs, beyond the goto-location functionality (see Locations.GotoLocation, ...).
- James
12-22-2011 04:59 PM
I agree with James. I use the Full Featured UI to debug/develop all the time, because my modified UI contains a Image Display used in my Vision Tests which I need to see while debuging. Can't do that with the Sequence Editor. The navigation buttons are what I miss the most using the UI instead of the editor.
I've started to develop my own forward/back buttons using the "Locations" Class. Seems pretty straightforward although my "AddFileLocation" method is currently thowing an error.....
12-27-2011 10:47 AM
Cabman,
What kind of error is the AddFileLocation throwing?
Regards,
Kyle Mozdzyn
Applications Engineering
National Instruments
01-03-2012 10:16 AM
Fixed that issue. The problem was I had created a new engine reference instead of Getting the Engine reference from the Application Manager.
I didn't get very far with this. About all I accomplished was to get the SequenceName from the Location property. The "StepName" returns nothing, I assumed it would give me the step currently selected in the UI.
Details:
I use the "GetEngine Method" from an Application Manager reference to get a reference to the Engine.
I pass that to the "New Locations method" to create a Locations object.
I use the "AddFileLocationByObject Method" to add the file Locaton to the object. The object reference I use is from the "AsPropertyObject Method" from the Sequence file reference. (from the SequenceFileViewMgr)
I use the Location property on the Location object to get the SequenceName, but am unable to get the StepName.
Location(s) documentation seems sparce on the NI site. I thought I could queue the StepName in a stack then use the GotoLocation Method to jump back to that step when click on a "Back Button". But I'm not getting the current StepName selected.
What am I missing?
01-04-2012 09:42 AM
Are you passing the step as the object to AddFileLocationByObject? If not, why not?
-Doug
01-04-2012 05:22 PM
I wasn't since passing the object from the "Sequence.GetStep" Method was giving me a 'Wire: Class conflict' error. Because of your question I read the Help more closely and realized I had to pass it as a 'Property Object'.
The code is currently adding step/sequence locations and I can read them back. Making progress...