Jump to content

Aristos Queue

  • Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by Aristos Queue

  1. If you want to run the VI in the IDE as a tool of some sort, save it into the "<LabVIEW>\project" subdirectory. Every VI in that directory gets automatically picked up and added to the Tools menu. The menu item gets its text from the display name of the VI, saved in VI Properties. When the menu item is chosen, your VI is run in an isolated application instance so it never interferes with running applications. App instance isolation is how all the G parts of the IDE execute, like the icon editor, the getting started window, or the right-click menus.
  2. I noted a few uses of lowercase "boolean". Capitalizing that B is often confusing because it is the only non-class type that is typically capitalized. Text languages have solved this by using keyword "bool", and therefore that is the actual type name. LabVIEW doesn't typically type out data types. NI style guide says to capitalize Boolean. Does LV wiki agree? When I'm editing the wiki, I will generally follow NI documentation style guidelines (so "subVI" instead of "SubVI", for example). Are there any particular conventions that the community has established that differ from NI standa
  3. I tried to update this existing image with a new version of the PNG: https://labviewwiki.org/wiki/File:Screen_Shot_2019-06-27_at_1.50.14_AM.png#file I keep getting an error: [XSir2GJrsGEvUGpzBj7-DAAAAAQ] 2019-07-12 15:48:40: Fatal exception of type "Wikimedia\Rdbms\DBQueryError" Anyone know what's wrong?
  4. Are those 10 charts in the first image all screen shots from LabVIEW? If so, very nice! Professional work!
  5. MartinD: no, nothing wrong with that, but I usually only use that approach when the value is a computed value that needs different data storage. For example, “determinant” of a matrix... sparse matrix and dense matrix have different data storage, and determinant is computed differently for each type. But it works fine in your case, too. It’s nice if some classes have it as a variable (gets stored per object), but other classes it is constant for all objects of the class, so the method can just return a constant and not burden every object with that bit of data.
  6. Honestly, I have no idea if that’s something that is even logically possible. Computing data flow from procedural instructions is one of the holy grails of compiler optimization. Sure, there’s short segments that are easy to translate back, but a general app? Maybe, but I have 19 years of LabVIEW R&D experience with the compiler, and I’d be hard pressed to do it by hand, much less derive a general algorithm for automatic decompilation.
  7. I pro-indicate them (opposite of contraindicate?) because despite some issues over the years, they have some abilities that nothing else in LV replicates, and I've learned where the rough edges are. There are some really sophisticated tools that can be built from these controls (even the Q Controls can't help out while editing). I've built multiple XControls that work just fine in built apps and large projects. YMMV.
  8. Someday, I really would like to take two months off of my main dev job to sit down with the developers of some app that uses all this ref stuff and really tear it apart. I've gone through smaller apps and been able to eliminate most of the references, achieving much better performance -- often with a significant decrease in memory and usually fixing a couple of race conditions along the way! But that's only for small apps, which leaves my theory that the big apps would be better off without the ref aspects as just that: a theory. I don't just need my time... I'd also need the time of the large
  9. PS: ShaunR's new XControl is pretty nifty.
  10. The rusty nails are never-released features that aren't supported. XControls very much are supported and are useful, just not as useful as we all wish they were. Big difference.
  11. @AbdulQuader As Rolf says: Yes. You can trivially build one just by building placeholder subVIs that either do nothing or return dummy data when called, and then fill in those subVIs with real hardware calls later. But more sophisticated simulations are very application specific. Unfortunately, there isn't (and cannot be) a general "HW simulator API". This guide to building a hardware abstraction layer may help you design one for yourself. Or it may not help -- the PDF is one that I've handed around to many users, and it's about 50/50 chance of people either happy it is so helpful o
  12. @CheesyGC what is an example of "dynamically building a project" question? I can think of a few interpretations... dynamically loading modules/plugins or dynamically building the build specs. Both of those are pretty common (the latter is sufficiently common that NI just rolled out new CLI tools to support doing it).
  13. I think the XControl questions should stay. Any CLA should be able to recognize/use/edit an XControl because it is a part of the language, and not an obscure part (like, for example, "Enable Database" on a subVI). They do have real uses. For me, they're the best way to put a UI element together to display a LV class. We are still years away from a general user-base migration to NXG -- I think it is too soon to be making those arguments (as a counterargument, I think CLAs should know what scripting is, even though most scripting functions are not going to migrate to NXG). (The exact number
  14. Copy cannot be auto-generated because your object might contain references and the copy routine has to decide whether to share or clone the references. Mikael’s answer is best. Obviously if the parent class doesn’t have a Clone method, then you cannot add one to the child.
  15. Call change to constant afterward if it matters to you (nearly zero effect on generated code since Open VI Ref cannot be constant folded). But (I’m not at machine right now) it would surprise me if that same property weren’t on the constant. You should check To get the conpane of a VI: https://zone.ni.com/reference/en-XX/help/371361R-01/lvscript/vi_connector_pane058datatype/ Or use this method on App refnum if the VI is not in memory (it reads the conpane without loading the VI): https://zone.ni.com/reference/en-XX/help/371361R-01/lvscript/app_getviconpane_datatype/
  16. The method I think you’re looking for is this one: https://zone.ni.com/reference/en-XX/help/371361R-01/lvscript/virefnum_set_conpane/
  17. With our built-in controls, the problem is solved at the moment of selection. If the main part is selected (e.g. the LED part of a Boolean control) then all of the related parts are also selected. If a secondary part is selected (e.g. the label of the Boolean control) then only that part is selected. Thereafter, the rules of the selection list work as normal -- when you drag one item in a selection, all selected items move with it. This is what allows you to select the label of several different controls at once.
  18. LV 2019 augments the right-click menus for class wires/terminals to provide a method list you can drop, which should alleviate this issue. I found a way to make the right-click menu plug-in able to add the graphical palette menus and then built a right-click plug-in that builds the method palette on the fly if the class doesn't already have its own default palette.
  19. That is really weird. I haven't tried to replicate... not sure I'll have time for a while... but there's one odd thing to try... after the "Remove VI" call, try adding a "Wait MS" of about 100 milliseconds. I'm trying to come up with hypotheses that would cause this problem, and the only one I can think of is that the subpanel is opening its own reference to hold the panel in memory and that is (for some unknown reason) flagged to show the Save Changes dialog. I'm torn between hoping this works you around the bug and hoping that it has nothing to do with it.
  20. I got a PSE to work on this for a while this week. We couldn’t replicate the issue. It’s a pretty bad bug — wiping out the whole directory. If you have more explicit steps to reproduce, please consider filing a bug report with NI.
  21. If you open it with Open VI Ref and then close it before calling Close Reference, there shouldn't be a Save Changes dialog. The only way I replicate is if I leave the panel open after the VI finishes running and then the user closes that panel (which is correct behavior). Is that what you're doing?
  22. PS: Did I mention that the design of these things was arcane and bad? Yes? Ok. 'Cause it's true. I have a long list of lessons I hope NXG learns.
  23. XControls work just fine... if you dance with them the way they were intended. *head bang* If you don't want data to be saved, one way is to not put it in the State data. If you only need the data in the facade, add a shift register. But if you need it lots of places, put a global unique ID (GUID) in the XControl's state data, something that never changes after creation, and create an LV-2 style global with a lookup table from the unique ID to the data. You can create GUIDs on any LV OS using: LabVIEW 2017\resource\Framework\Providers\API\mxLvGenerateGuid.vi Changing the s
  24. @Yassamina BERKANE The answer is the same as it was in 2006: dequeue and concatenate. A ragged 2D array is not (and never will be) meaningful in LabVIEW. Because the compiler cannot guarantee that you're going to add arrays of all the same size to the queue (you might be doing that, but it cannot be proven from code because refnums can be shared all over the place), any attempt to ask for all the queue elements in one array will have them each wrapped in a cluster. If you dequeue and concatenate, you can build a 2D array yourself.
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.