Ano Ano Posted May 12, 2011 Report Share Posted May 12, 2011 Hello, I want to find away to reinitialise to default about 40 indicators at the start of my program. I am doing this because when I run the program again it uses the values that it previously had from the last run. I could use an invoke node 40 times but this is a bit tedious Does anyone know how to do it? Quote Link to comment
MikaelH Posted May 12, 2011 Report Share Posted May 12, 2011 Use the VI Property Node: Default Values->Reinitialize All values to Default. //Mike Quote Link to comment
gleichman Posted May 12, 2011 Report Share Posted May 12, 2011 (edited) Hello, I want to find away to reinitialise to default about 40 indicators at the start of my program. I am doing this because when I run the program again it uses the values that it previously had from the last run. I could use an invoke node 40 times but this is a bit tedious Does anyone know how to do it? I didn't find the property node that Mike mentions, but there is a method. I used it to create a little utility VI that finds all controls and resets them to default. GUI - Set all Controls Default.vi Edited May 12, 2011 by gleichman Quote Link to comment
Jon Kokott Posted May 12, 2011 Report Share Posted May 12, 2011 (edited) I didn't find the property node that Mike mentions, but there is a method. I used it to create a little utility VI that finds all controls and resets them to default. I think it is an invoke node. http://forums.ni.com...ode/td-p/768440 ~Jon Edited May 12, 2011 by Jon Kokott Quote Link to comment
Ano Ano Posted May 12, 2011 Author Report Share Posted May 12, 2011 Use the VI Property Node: Default Values->Reinitialize All values to Default. //Mike I cannot find this node, any chance for a print screen? Quote Link to comment
gleichman Posted May 12, 2011 Report Share Posted May 12, 2011 I cannot find this node, any chance for a print screen? There isn't a property node. It's an invoke node. Did you look at the code that I posted? If you don't want to use that utility: right click on control -> Create -> Invoke Node -> Reinitialize to Default Quote Link to comment
Jordan Kuehn Posted May 12, 2011 Report Share Posted May 12, 2011 See the attached screen shots. Quote Link to comment
ShaunR Posted May 12, 2011 Report Share Posted May 12, 2011 Note that this invoke node will not clear tables or combo-boxes which I've always found infuriating 1 Quote Link to comment
crelf Posted May 13, 2011 Report Share Posted May 13, 2011 Note that this invoke node will not clear tables or combo-boxes which I've always found infuriating Get that on the LabVIEW Idea Exchange! Unless it already is, and in that case: link me to it! Quote Link to comment
jgcode Posted May 14, 2011 Report Share Posted May 14, 2011 Note that this invoke node will not clear tables or combo-boxes which I've always found infuriating That is not quite correct. Tables will be cleared (or rather, set to Default) using that IN as their datatype is a 2D Array of Strings. Combo-boxes have a String datatype so that will Default the 'selected item' (which is what the datatype refers to) not the actual list data in the combo-box which is persistent and accessed through e.g. Strings[] PN. IMHO this behaviour is expected and should not be changed. Quote Link to comment
ShaunR Posted May 14, 2011 Report Share Posted May 14, 2011 Get that on the LabVIEW Idea Exchange! Unless it already is, and in that case: link me to it! I don't know if it is there or not. I don't visit the NI sites much any more since it kept asking me to verify my details-so I don't bother now. But we have over a year to argue about it before it is likely to be considered That is not quite correct. Tables will be cleared (or rather, set to Default) using that IN as their datatype is a 2D Array of Strings. Combo-boxes have a String datatype so that will Default the 'selected item' (which is what the datatype refers to) not the actual list data in the combo-box which is persistent and accessed through e.g. Strings[] PN. IMHO this behaviour is expected and should not be changed. Well. We are about to argue about semantics. I didn't say what it should do, just that I find it irritating that it doesn't and pointing out that if the OP uses it, it probably won't do what they (and I) expect for those controls. Quote Link to comment
jgcode Posted May 14, 2011 Report Share Posted May 14, 2011 Well. We are about to argue about semantics. No, more like details -> Tables will default correctly using the IN (you said they wouldn't above). Quote Link to comment
ShaunR Posted May 14, 2011 Report Share Posted May 14, 2011 (edited) No, more like details -> Tables will default correctly using the IN (you said they wouldn't above). Ok. Just for you I mean a Multicolumn List Box (which is a table to a simpleton like me ) rather than a Table Control. So yes you are right a "Table Control" does work. Not all table-type controls do though. Edited May 14, 2011 by ShaunR Quote Link to comment
Aristos Queue Posted May 14, 2011 Report Share Posted May 14, 2011 Get that on the LabVIEW Idea Exchange! Unless it already is, and in that case: link me to it! Or don't since the method reinitializes the value property to default and those things *are not* values. It would be really frustrating for apps that don't dynamically populate their tables etc if LV wiped out the content every time the value was reset. Rings shouldn't be wiped, neither should tables. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.