Ernest Galbrun Posted March 16, 2012 Report Share Posted March 16, 2012 (edited) Hello again dear labviewers. I come back to labVIEW after a couple of years doing painful things, and indeed labVIEW is great and fun (IMO). However I am a little bit rusty and I would really appreciate your insight on my project. So here is the thing : I have a class, let's call it class A. Associated with this class is a very fine Xcontrol (whose data is of type 'A') which permits interaction with the user. I have yet another class, that I will henceforth call class B. B has a handful of As in its private data member. For elegance sake, I would appreciate if it could own as many As as the Universe would permit, but practically it won't be more than 5. And I have another XControl for B allowing more sophisticated interraction with the user. And of course this interaction involves using A's xControl in the front panel of B's xControl. Here I have settled for a hard defined maximum number of A's xControl instances. I can't figure out what kind of architecture I should use there. My first attempts were failures, eventually leading to an irrecoverable crash of my project (I think it was due to some kind of circular reference), so I have a nice opportunity to start everything again from scratch. What should/could I put in B's private data member ? an array of As ? an array of references to As ? What should/could I use as my xControls data type ? The natural answer is the same type as the class I wish to assaciate it with, but somehow I wonder if it can work in this case ? And most importantly : How do I connect the As that are instanciated in B's xControl with the As that are owned by B in B's xControl data ? thanks, Ernest Galbrun. Edited March 16, 2012 by Ernest Galbrun Quote Link to comment
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.