ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

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

labview

Thank you , Ill discuss that with my boss. But give suggestion for this problem also

Boldness has genius, power and magic in it!'
0 项奖励
21 条消息(共 23 条)
1,160 次查看

@MaveenD wrote:

dude It took a lot of time to do it . But i haven't followed pattern or template .



That's why it would have been better to start small with only a few channels of data to work with.  Figure out an architecture that would allow you to expand to the 127 or more channels you have BEFORE you put in all that work trying to copy and lay out all of those wires.

 

Create arrays of all your channels.  Use auto-indexing of those arrays in a For Loop rather than creating 127+ copies of the ADSOCX function.  With a bit of time creating that first array and using loops, you can at least have functionally the same code with perhaps 3 or 4 screens of code rather than 120 screens.

0 项奖励
22 条消息(共 23 条)
1,159 次查看

I modified the structure of your code significantly to make it take less than a screen.

 

You'd have to replace the string array with one that contains all of your channels.  You'd need to use Index Array to take the results array and break it down to each indicator.  (Note Index Array stretches downwards, no need to copy it or use the index input.)  Another concept is you can use an array of references to each indicatorl and write the value to each indicator using the value property node based on the auto-indexed reference.

 

Put the file writing part back in.

 

The filename reflects the new smaller size.

0 项奖励
23 条消息(共 23 条)
1,150 次查看