Setting a Property and set it to the max date value

from Spotfire.Dxp.Data import DataPropertyClass

#get document property
maxDateProperty = Document.Data.Properties.GetProperty(DataPropertyClass.Document, "myMaxDateDocumentProperty")

#get the newest date
maxDate = Document.Data.Tables["Data Table].RowValues.GetMaxValue().Value

#set document property to newest date
maxDateProperty.Value = maxDate.ToString()
Previous
Next Post »