Hi all,
Recently, I've been trying to load an Excel file using Python Creator.
reader = fmeobjects.FMEUniversalReader('Excel', False)
reader.open(FME_MacroValuesF'SourceDataset_XLSXR'])
feature = reader.read()
while feature:
attributes_list = feature.getAllAttributeNames()
for attr in attributes_list:
attr_value = feature.getAttribute(attr)
feature.setAttribute(attr,attr_value)
self.pyoutput(feature)
feature = reader.read()
reader.close()
Unfortunately, the above reading process loses the feature schema.
Is it possible to use Python FME API to expose all attributes or load a feature schema from a source file?