Geo G Posted October 9, 2017 Share Posted October 9, 2017 I have a table visualization and want to change the data source to it at the click of a button. Also, want to be able to select the columns to be displayed . Can this be done using a script Link to comment Share on other sites More sharing options...
Shandilya Peddi Posted October 9, 2017 Share Posted October 9, 2017 Hello George, You can use the below script to change the data source of a TablePlot and also select the columns from Spotfire.Dxp.Data import * from Spotfire.Dxp.Application.Visuals import * from System.Collections.Generic import List #Different Data Tables table1=Document.Data.Tables["table1"] table2=Document.Data.Tables["table2"] #list of Column to add listofColumns=List[DataColumn]() for column in table1.Columns: #excluding column "columnName" from the list if column.Name!="columnName": listofColumns.Add(column) #Add a script parameter "table" referring to the TablePlot visualization in the analysis tableVis=table.As[TablePlot]() tableVis.Data.DataTableReference=table1 tableVis.TableColumns.AddRange(listofColumns) Link to comment Share on other sites More sharing options...
Geo G Posted October 9, 2017 Author Share Posted October 9, 2017 Thanks ver much. Is it also possible to order the columns via script How about color coding Link to comment Share on other sites More sharing options...
Vishakha Mujoo Posted October 10, 2017 Share Posted October 10, 2017 Please register for 10th Oct Dr spotfireOffice hours for an alternative solution Link to comment Share on other sites More sharing options...
Mohd faizal Adris Posted August 17, 2020 Share Posted August 17, 2020 How can I clear the current table plot column Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now