2014-09-02, 04:38
(2014-08-23, 20:18)emveepee Wrote: Thanks for the post drJoju that got me to something I've been trying to do for a while. Rather than iterating it might be worth trying this, the logic works for me.
Code:for elem in root.findall(".//setting[@id='arduino_port']"):
elem.set('values', available_ports)
Martin
To follow up on my earlier post this code needs ElementTree 1.3 so it don't work on Android or OSX yet.
I still find settings.xml better than fileenum.in my case. Adding and removing files isn't efficient.
Martin