03-07-2022 07:40 PM
How do I add property/invoke nodes that are deprecated by NI and where can I find help documentation for these nodes? Like the OPEN:VI FROM BUFFER in the attachment, I googled a lot of keywords, but have no clue. Or is there a VI that includes all nodes deprecated by NI, this problem has troubled me for a long time, please help me
03-07-2022 07:55 PM
Deprecated nodes are not supposed to be used for new designs and are also a sign that the support for them will be removed in near future.
Any reason you would want to use something that is not supported?
03-07-2022 08:08 PM
Because there is an old program that has nodes in the attachment, it works fine in some specific cases, and it doesn't work in most cases. Because there is no relevant help documentation, I don't know how it works (what does buffer represent), and I haven't found an alternative in the new version of labview (2019), so I ask this question
03-08-2022 01:26 AM
I would assume it does the same job as Open VI ref.
03-08-2022 02:51 AM
I'm not aware of any way of accessing deprecated items in the editor, although there might be an INI key for it. You could possibly use some scripting tricks to get to them, but I haven't tried.
Presumably, you don't actually need that, since you already have the VI which calls the deprecated method, so you could just copy that code if you want. I'm not entirely sure about this, but I believe that at least for deprecated features which were official, their context help should include a section about what they were replace with. I doubt this particular method was ever made public, but you should still try looking at its context help.
As for what it does, it takes a binary string representing a VI and then loads that VI without going through the disk, returning a reference you can use. You could probably do this by writing that binary data to a file and then using Open VI Reference with that file path.
03-08-2022 03:15 AM
@tst wrote:
As for what it does, it takes a binary string representing a VI and then loads that VI without going through the disk, returning a reference you can use. You could probably do this by writing that binary data to a file and then using Open VI Reference with that file path.
It sounds similar to Open VI with just a name? Those VIs should already be in memory i.e. in a buffer?
03-08-2022 03:42 AM
@Yamaeda wrote:
It sounds similar to Open VI with just a name? Those VIs should already be in memory i.e. in a buffer?
No no! It takes the binary data of a VI as it is saved in a file on disk but from a byte array buffer in memory. So basically VI Open Reference with a path parameter is more or less equal to:
- Read file from path into a memory buffer
- Call VI Open from Buffer with this memory buffer
It's the memory buffer streaming version of VI Open.
In reality it is more complex to make it more performant but still the principle is like that.
03-08-2022 05:04 AM
@rolfk wrote:
@Yamaeda wrote:
It sounds similar to Open VI with just a name? Those VIs should already be in memory i.e. in a buffer?
No no! It takes the binary data of a VI as it is saved in a file on disk but from a byte array buffer in memory. So basically VI Open Reference with a path parameter is more or less equal to:
- Read file from path into a memory buffer
- Call VI Open from Buffer with this memory buffer
It's the memory buffer streaming version of VI Open.
In reality it is more complex to make it more performant but still the principle is like that.
That's why i specified the String version with only a Name, there should be no file read on that one, right? Or am i missing something?
03-08-2022 05:17 AM
@Yamaeda wrote:
That's why i specified the String version with only a Name, there should be no file read on that one, right? Or am i missing something?
Well no of course not. It only works on VIs already in memory. But it references them by their name. This one is very different. The buffer contains the binary data of the VI. And the VI does not have to be already loaded. Basically think of it like a method to open a VI that you for instance received over some network communication as binary stream. Instead of having to write it onto disk and then open it from there, you can directly open it from the data in memory.
03-08-2022 09:16 AM
"Open VI From Buffer.vi" provides equivalent functionality.
"Open VI From Buffer.vi (deprecated)" contains the deprecated node.
To be able to set any node yourself:
Place "Set Property or Method.vi" in C:\ ... \LabVIEW 200x\project\ ...", then restart LabVIEW.
Select (click on or lasso) a property or invoke node, then Menu → Tools → Set Property or Method