LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Excel sorting using Report Generation Toolkit

Solved!
Go to solution

Hello,

 

The query is related to Excel sorting using Report Generation Toolkit.

Initially I'm writing the values in three columns continuously. Once the while loop is stops the third column (C) should be arranged in ascending order and the depending columns 1 & 2 also change accordingly.

 

Please find the enclosed .Zip file and help me to solve the issue.

 

Regards,

S Nagaraju

 

0 Kudos
Message 1 of 5
(3,640 Views)
Solution
Accepted by Sonti_11532

Its better to collect all the data in an array and then sort the values (Ascending order) then write into the excel which will solve your problem in an easy way

----------------------------------------------------------------------------------------------------------------
Palanivel Thiruvenkadam | பழனிவேல் திருவெங்கடம்
LabVIEW™ Champion |Certified LabVIEW™ Architect |Certified TestStand Developer

Kidlin's Law -If you can write the problem down clearly then the matter is half solved.
-----------------------------------------------------------------------------------------------------------------
0 Kudos
Message 2 of 5
(3,632 Views)
Solution
Accepted by Sonti_11532

I think you are using the RGT for Excel "the hard way".  Here's a suggestion -- in the Search box on the Forum, type the word "Revised " (don't type the quotation marks, but do put the space after it).  Go to the "Obvious choice" and read what I wrote several years ago about using the RGT for Excel.

 

One difference is that I strongly recommend the Excel Easy Table functions instead of Append Report Text.  Among other things, it will allow you to keep numeric data as numbers (which facilitates sorting).  If you want to Sort, use Excel Sort Data (found on the Excel Advanced Palette).  Note that these Excel-specific functions use the Position cluster directly -- you don't have to unbundle the MS Parameter cluster to get it.  There are also two functions to convert between Excel "A1" addresses and Excel Row/Column indices (e.g. B1 = row 0, column 1).

 

Bob Schor

Message 3 of 5
(3,615 Views)

Hello Palanivel,

 

As you mentioned sorting 1D array is easy way but my data is 2D array. Based on Third column (in Ascending order) remaining columns also adjusted accordingly.

 

For example:

Input data:

1.2          2.6          3.12

6.2          2.9          17.8

0.6          3.4          2.04

8.1          2.29        23.49

Output data: should be in this format

0.6          3.4          2.04

1.2          2.6          3.12

6.2          2.9          17.8

8.1          2.29        23.49

 

Help me to implement this one in programmatically.

 

Regards,

S Nagaraju

0 Kudos
Message 4 of 5
(3,589 Views)

Hello Bob Schor,

 

Thank you very much for your suggestions.

I will try those changes.

 

Regards,

S Nagaraju

0 Kudos
Message 5 of 5
(3,587 Views)