I am learning Python to create toolbox right now. When I'm trying to get the parameter, using valueAsText, the date returned is unicode instead of a list that I was expecting.
This is the code that I was using:
inFeatures = parameters[0].valueAsText
I was hoping the input data would be stroed in a list in this way, put when I use for loop, this is what I have:
messages.addMessage(type(inFeatures))
for inFeature in inFeatures:
messages.addMessage(inFeature)
It is dividing the path into single characters.
Any way I could get the result in a list?
Thanks.
Aucun commentaire:
Enregistrer un commentaire