DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

How to count row in a channel with VB

 

Hello every body,

 

First, I'm quite new in VB script and I hope you will excuse me if the question seems stupid. I have several columns with an undefined number of row (for each file; the number of row will be different). As I want to automate the process, I need to know how many row I have per channel, each time I load data from a file (created by a LV programm)

 

thanks to those able to help me.

HerveM

0 Kudos
Message 1 of 2
(4,068 Views)

Hello HerveM,

 

There are several ways get the the number of rows, here are two:

 

L1 = Data.Root.ChannelGroups(1).Channels("Temp_F").Properties("length").Value
L2 = CL("[1]/Temp_f")

 

The first one is the object oriented method, the second one used the variable CL (Channel Length) to get the number of rows. They both work, and are up to your preference ...

 

Hope this helps,

 

   Otmar

Otmar D. Foehner
Message 2 of 2
(4,066 Views)