取消
显示结果 
搜索替代 
您的意思是: 

VIM Label Setting on Indicator In Cluster

已解决!
转到解答

I'll ask my question first, then say why I need it, and then someone hopefully tell me I'm crazy.

 

So I have a VIM and I want to use it to set the data type that another developer wants for some thing that will be used down the line.  Think like the Obtain Queue where you define the data type, then the Dequeue knows the data type from wire of the obtain.  The data type created will be a cluster which contains Maps and a couple of other things.  I sorta need to reference these cluster elements by name, but this VIM defaults to the names, of the functions that created them.  How can I have the data type of the cluster be dynamically set by the VIM, but have the label of the element in the cluster be a constant?

Initialize Map Cluster Label Issue.png

 

Okay so now the reason.  I need to reference these cluster elements and the best way is probably by using the normal Unbundle and Bundle functions.  I'd prefer using the Unbundle and Bundle by name.  I thought I could live with the normal Bundle/Unbundle, but I actually need to use the In Place structure to access the cluster, since the compiler isn't smart enough to realize I'm using the same cluster, and performance tanks with large amounts of data.  About 100 times slower then if I use the IPE structure.  I could reference "map" in my other VIMs, but it no longer is self documenting on what "map" is what and the purpose of the data.  Thanks.

0 项奖励
1 条消息(共 6 条)
1,730 次查看

I don't know if there is a solution. I had a similar issue, see

 

https://forums.ni.com/t5/LabVIEW/Different-Results-VIM-and-subVI/td-p/4056636?profile.language=en

 

Names are not propagated in VIMs it appears, by choice.

 

mcduff

0 项奖励
2 条消息(共 6 条)
1,705 次查看

You can use my relabelling Xnode.

"If you weren't supposed to push it, it wouldn't be a button."
3 条消息(共 6 条)
1,671 次查看

Here's a simplified version using my "Relabel and Default Value.xnode" and setting the output to be the default value.

"If you weren't supposed to push it, it wouldn't be a button."
0 项奖励
4 条消息(共 6 条)
1,664 次查看
解答
接受人 Hooovahh

If you've seen my Malleable Buffer experiment, I use a "Name the Buffer.vim" to fix a name for my buffer.  This VIM just passes one input to one output (naming the output).  This would let you name your map "Value Map".

5 条消息(共 6 条)
1,660 次查看

Wow those are some amazing suggestions thanks guys.  I tend to go with a VIM over an XNode if both can do what I want and in this case a simple VIM of input and output does the job.  

 

However that XNode is cool and I would also give it the solution except for one issue.  I can't have the XNode in a file that is inlined, and the file I want to use it in is a VIM, which needs to be inlined.  Sorry Paul runner up for you.

0 项奖励
6 条消息(共 6 条)
1,592 次查看