1 2 3 4 5 6 7 | from Spotfire.Dxp.Data import DataManager from Spotfire.Dxp.Data import IndexSet from Spotfire.Dxp.Data import RowSelection marking=Application.GetService[DataManager]().Markings[markingName] selectRows = IndexSet(dataTable.RowCount, False) marking.SetSelection(RowSelection(selectRows),dataTable) |
Input:
markingName (String): The name of the marking profile to clear.
dataTable (Data Table): The data table that currently has the marking applied.
Hi, Is there a way to clear markings when the filter settings are changed? Thanks!!!
ReplyDeleteThis comment has been removed by the author.
ReplyDeleteHi,
ReplyDeleteI am wondering if there is a way to store the active marking for a data table in a variable, then reapply this marking after a data reload has been performed?
This comment has been removed by the author.
Deletefrom Spotfire.Dxp.Application.Visuals import VisualContent
Deletefrom Spotfire.Dxp.Data import IndexSet
from Spotfire.Dxp.Data import RowSelection
vc = vis.As[VisualContent]()
dataTable = vc.Data.DataTableReference
marking = vc.Data.MarkingReference
remark = Document.ActiveMarkingSelectionReference.GetSelection(Document.ActiveDataTableReference).AsIndexSet()
#Refresh PHAT Data Table
if table.IsRefreshable and table.NeedsRefresh:
table.Refresh()
#Remark correct rows
marking.SetSelection(RowSelection(remark),dataTable)
Script Parameters:
vis as Visualization
table as Data Table
THanks for sharing
ReplyDeletegclub casino