Jump to content

In a Cross Table, how do I change the width of the columns all at the same time.

Guillermo Chutrau 2

Recommended Posts

Hi there,

We changed this behaviour in Spotfire 7.6. Previously it was only possible to size all columns all at once, which we felt was too restrictive, so we can now set individual column widths. We chose this to replacethe functionality to size them all at once. There's no concept of column selection in a cross table so that won't work either.

You can set the cross table cell width using IronPython - that should set all columns to the same width. Something like:

from Spotfire.Dxp.Application.Visuals import *

vis = vis.As[CrossTablePlot]()

vis.CellWidth = 100

Pass in the cross table plot as a parameter to your script called "vis".

Andrew (TIBCO Data Science)

Link to comment
Share on other sites

  • 1 month later...

So you can not adjust the column widths individually in a cross table prior to 7.6  At least this is what I see which is really stupid.  So I have to make all columns huge just so I can see the data in one particular one


This ranks right up there with removeing the scroll arrows, especially on the filter boxes so you only have  a slider bar.  Who could have possibly thought these were good ideas

Link to comment
Share on other sites

  • 1 year later...

Hi@andrew, your script works for the columns, but I've got this scenario where I have column names on the Y-axis whichcan be changed by slider, when I change the slider,the column width is not fixed and it gets clumsyeverytime, users have to adjust the column width everytime time in web player when they access and itis annoying, is there a solution for that!! attached pictures I think you will have better understanding


PS: I posted it as an answer because for comments I didnt get any option to upload picture, sorry!!!

Link to comment
Share on other sites

  • 3 months later...
I'm very green regarding scripting. What would be the best way to run the above script for multiple cross tables. Spotfire keeps crashing on me and I think it may be passing in multiple parameters/visualizations with the same "vis" name. 
Link to comment
Share on other sites

  • 5 months later...
  • 11 months later...

Hi Andrew, I have the same issue: I always need to manually change each column size to have my crosstable layout properly. When I select all column only the size of one will change as opposed to for example changing text orientation. How do I change the width of all the columns simultaneously



Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...