02-02-2022 07:28 AM
wiebe@CARYA wrote:
I can't get it working either. At least not with XML.
I'm pretty sure it's something in LabVIEW preventing this.
Flattened data seems to work. I have only tried this with copy-paring data, so not with automated string manipulation. However, copy-paste flattened data works, while copy-pasting XML doesn't.
My guess is that they did that to prevent code from violating private scope; and that the fact that flattening/unflattening works is probably an oversight, which they might "fix".
02-02-2022 09:26 AM
@paul_cardinale wrote:
wiebe@CARYA wrote:
I can't get it working either. At least not with XML.
I'm pretty sure it's something in LabVIEW preventing this.
Flattened data seems to work. I have only tried this with copy-paring data, so not with automated string manipulation. However, copy-paste flattened data works, while copy-pasting XML doesn't.
My guess is that they did that to prevent code from violating private scope; and that the fact that flattening/unflattening works is probably an oversight, which they might "fix".
It doesn't give that much problem in the normal context. The hole point of From\To XML\JSON is for getting\setting (class) data.
02-02-2022 11:15 AM
wiebe@CARYA wrote:
@paul_cardinale wrote:
wiebe@CARYA wrote:
I can't get it working either. At least not with XML.
I'm pretty sure it's something in LabVIEW preventing this.
Flattened data seems to work. I have only tried this with copy-paring data, so not with automated string manipulation. However, copy-paste flattened data works, while copy-pasting XML doesn't.
My guess is that they did that to prevent code from violating private scope; and that the fact that flattening/unflattening works is probably an oversight, which they might "fix".
It doesn't give that much problem in the normal context. The hole point of From\To XML\JSON is for getting\setting (class) data.
Flatten to JSON won't take a class.
02-03-2022 03:03 AM
@paul_cardinale wrote:
wiebe@CARYA wrote:
@paul_cardinale wrote:
wiebe@CARYA wrote:
I can't get it working either. At least not with XML.
I'm pretty sure it's something in LabVIEW preventing this.
Flattened data seems to work. I have only tried this with copy-paring data, so not with automated string manipulation. However, copy-paste flattened data works, while copy-pasting XML doesn't.
My guess is that they did that to prevent code from violating private scope; and that the fact that flattening/unflattening works is probably an oversight, which they might "fix".
It doesn't give that much problem in the normal context. The hole point of From\To XML\JSON is for getting\setting (class) data.
Flatten to JSON won't take a class.
Just XML then.
02-03-2022 03:42 AM
@MaddinDorn wrote:
Hello,
I've tried LVOOP and found that it's more cumbersome to debug small Vi. The nice thing about LabView is,
that you can debug each Vi individually by setting the parameters on the front panel. But in LVOOP the data in the
Clusters are stored by the object and I can't toggle them from the front panel. Therefore I would have to create a new Vi and parameterize the cluster to the respective data and then start my desired vi afterwards. This is very cumbersome, is there a simple solution?
I've been thinking about this, and one solution is to make more private functions that don't use the class wire for data, but unbundle it outside, so it's more akin to 'classic' functions.
So instead of unbundling class data and calculate it as one function, you have a private function that works on an array and a wrapper that unbundles and calls this function.
Would that work?
02-04-2022 05:45 AM
@Yamaeda wrote:
@MaddinDorn wrote:
Hello,
I've tried LVOOP and found that it's more cumbersome to debug small Vi. The nice thing about LabView is,
that you can debug each Vi individually by setting the parameters on the front panel. But in LVOOP the data in the
Clusters are stored by the object and I can't toggle them from the front panel. Therefore I would have to create a new Vi and parameterize the cluster to the respective data and then start my desired vi afterwards. This is very cumbersome, is there a simple solution?I've been thinking about this, and one solution is to make more private functions that don't use the class wire for data, but unbundle it outside, so it's more akin to 'classic' functions.
So instead of unbundling class data and calculate it as one function, you have a private function that works on an array and a wrapper that unbundles and calls this function.
Would that work?
That's way too kludgy, even for me.
02-04-2022 07:02 AM
@paul_cardinale wrote:
That's way too kludgy, even for me.
It would be even more VI's, yes. 😕 The biggest problem with lots of VIs is coming up with decent names. 🙂
02-04-2022 07:16 AM
@Yamaeda wrote:
@MaddinDorn wrote:
Hello,
I've tried LVOOP and found that it's more cumbersome to debug small Vi. The nice thing about LabView is,
that you can debug each Vi individually by setting the parameters on the front panel. But in LVOOP the data in the
Clusters are stored by the object and I can't toggle them from the front panel. Therefore I would have to create a new Vi and parameterize the cluster to the respective data and then start my desired vi afterwards. This is very cumbersome, is there a simple solution?I've been thinking about this, and one solution is to make more private functions that don't use the class wire for data, but unbundle it outside, so it's more akin to 'classic' functions.
So instead of unbundling class data and calculate it as one function, you have a private function that works on an array and a wrapper that unbundles and calls this function.
Would that work?
I'm not sure I understand that last part.
You mean like making a private 'super accessor' for all data?
That wouldn't work outside the class (because it's private). Making it public would be a serious encapsulation breach.
Another problem is that such a function wouldn't update automatically when the private data is updated.(if a cluster is used). So maintenance is high and errors are very likely.
02-04-2022 09:35 AM
I'll throw together an example of my thoughts when i get home.