LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with table formatting, report generation toolkit

Highlighted

. I am having a problem that when Report Generation tool generates a table which is partly in the next page, the program does not follow the programmed formatting such as column background color and border came out to be different than rest of the tables. What is causing this problem? I have set the autoformatting of Word Easy Table vi to 0 as per https://forums.ni.com/t5/LabVIEW/Word-Report-Formatting-Troubles/m-p/3085614#M882023 

Vertical lines appear if autoformating of Word Easy Table vi is -1

 

2. Also, the RGB color in the tool do not result in the same color in the Word document.

 

Using: Labview 2017, Word 2010

0 Kudos
Message 1 of 7
(502 Views)

For the color issue, hit Ctrl + Space and search for Convert OLE Color. 

aputman
LabVIEW 2017
LabVIEW Programming
0 Kudos
Message 2 of 7
(473 Views)

Why did you resurrect that old topic by posting the same message that is in this thread?  Let the old forum topics rest in peace.  They remain there for your information and reference.  Another example for why we need ability to lock old threads......

aputman
LabVIEW 2017
LabVIEW Programming
0 Kudos
Message 3 of 7
(470 Views)

I used OLE color converter to generate RGB(214,227,188) but the table color came out to be RGB(192,192,192).

To see color use RGB color converter https://www.webpagefx.com/web-design/hex-to-rgb/ 

 

Attachment (New Tabl Color) shows the output colors in the table.

Attachment (OLE_Converter) is a screenshot of the block diagram.

0 Kudos
Message 4 of 7
(441 Views)

If you drill down in the borders and shading VI, there is a VI called "Word_LVtoWD_Color" that appears to be limiting the colors that can be used.  This may be based on an older version of Word that was limited to a smaller number of colors.  

aputman
LabVIEW 2017
LabVIEW Programming
0 Kudos
Message 5 of 7
(434 Views)

The problem is that the Word Table Borders and Shading.vi uses deep inside the Shading.BackgroundPatternColorIndex property (and not the Shading.BackgroundPatternColor property) and use the Word_LVtoWD_Color.vi to match the selected color to the closest wdColorIndex color. Using the OLE Converter will just make the resulting color more difficult to understand. The only solution is the make your own border and shading vi using the RGT Get ActiveX Reference.vi.

 

Ben64

--------------------------------------------------
The best way to say thanks is to give kudos!
0 Kudos
Message 6 of 7
(431 Views)

Let's deal with color problem a bit later and move the formatting issue.

My goal is to split a big table into small tables. When I used Append to Table vi, the tables were not generated like separate tables instead the data was overwritten and table rows were added for each iteration of the for loop. While Word Easy Table vi did not have this problem but the format settings are gone after 3 or 4 large tables (entire A4 size) or when a part of the small table is on another page.

0 Kudos
Message 7 of 7
(421 Views)