Hey!
We truly hope that our free tool comes in handy for your business, especially these days. Follow our news, stay safe & pivot on!

Pivot table cells width

Answered

How to assign aggregate column width?

3 answers

WebDataRocks Team WebDataRocks April 13, 2020

Hello,
 
Thank you for reaching out to us.
 
The width of the specified column, as well as the height of rows, can be adjusted using the tableSizes property of the report object.
 
It has the following structure:
tableSizes – Object. Contains information about table sizes:

  • columns – Array of objects. Each object is used to save and restore the width of some column in the report:
    • width – Number. Column width in pixels.
    • idx – Number. Column’s index, starts from 0.
    • tuple – Array. Consists of unique names that identifies the column in the table based on data in it.
    • measure(optional) – Object. Identifies the measure (this property is defined only if “[Measures]” is selected for columns in the slice). measure is used with tuple and is not set when idx is used. Has the following properties:
      • uniqueName – String. The measure’s unique name.
      • aggregation (optional) – String. The measure’s aggregation type. Please note, it’s necessary to use either idx or tuple, not both.
  • rows – Array of objects. Each object is used to save and restore the height of some row in the report:
    • height – Number. Row height in pixels.
    • idx – Number. Row’s index, starts from 0.
    • tuple – Array. Consists of unique names that identify the row in the table based on data in it.
    • measure(optional) – Object. Identifies the measure (this property is defined only if “[Measures]” is selected for rows in the slice). measure is used with tuple and is not set when idx is used. Has the following properties:
      • uniqueName – String. The measure’s unique name.
      • aggregation (optional) – String. The measure’s aggregation type. Please note, it’s necessary to use either idx or tuple, not both.

 
Please find out an example we have prepared for you.
 
Do not hesitate to contact us in case additional questions occur.
 
Kind regards,
WebDataRocks Team

Uma May 6, 2020

Can we set auto width for columns?

WebDataRocks Team WebDataRocks May 11, 2020

Hello,
 
Thank you for writing to us.
 
We would like to kindly explain that the width of each column is adjusted automatically to wrap the longest value contained by its cells.
 
In case another behavior is required, our team suggests providing us with additional details or a demonstration of the desired result.
 
We are looking forward to hearing from you.
 
Kind regards,
WebDataRocks Team

Please login or Register to Submit Answer