Search code examples
pythonironpythonspotfire

Iron Python Code Analysis


I have the below code of Iron Python to be used in Spotfire. From my understanding it can refresh particular data table. There is a commented part which seems to have a counter. I need an explanation on how the counter works and whether the existing code just refreshes the data tables.

Iron Python Code:

from Spotfire.Dxp.Application import *
from Spotfire.Dxp.Application.Visuals import *
from Spotfire.Dxp.Data import DataManager

myDocument=Application.Document
#myDocument.Properties["RefreshCounter"] = 0



DM = Application.GetService(DataManager)
DM.Tables.Refresh([table1, table2])

Solution

  • There is in Spotfire something like document property defined as below. https://docs.tibco.com/pub/spotfire/7.0.1/doc/html/other/other_details_on_new_edit_document_property.htm So developer seem to intended to just count have many times the refresh happened but in the code I dont see the moment where he increment the counter so it might have beeen deleted instead of commented out. Just an educated guess.

    The code just refreshes the table. As per http://spotfired.blogspot.com/2014/10/refresh-reload-datatables.html