Data table column properties

Description: Display data table column properties.
Assumptions: An optional 'myTable' data table type script parameter.

#Pick one of the following data table reference methods:
#myTable = Application.Document.Data.Tables['MyDataTable']        #Name method
#myTable = Application.Document.ActiveDataTableReference          #Active data table method
#myTable = Application.Document.Data.Tables.DefaultTableReference #Default data table method
#myTable as a data table type script parameter                    #Script parameter method

for c in myTable.Columns:
  print "Column Name: " + c.Name
  print "IsValid: " + str(c.IsValid)
  print "IsVisible: " + str(c.Visible)
  print "DataType: " + str(c.DataType)
  print "Origin: " + c.Properties.GetProperty('Origin')
  print "Expression: " + c.Properties.Item['Expression']
  print "Calcualted Expression: " + c.Properties.Item['CalculatedExpression']
  print "Column Type: " + str(c.Properties.Item['ColumnType'])
  print "Data Type: " + str(c.Properties.Item['DataType'])
  print "Description: " + c.Properties.Item['Description']
  print "External Id: " + c.Properties.Item['ExternalId']
  print "External Name: " + c.Properties.Item['ExternalName']
  print "\r\n" #Print a blank line