This sample demonstrates writing to an XML file, not reading. If you want to provide values to be written from temporary macros, just replace the strings with macro references, for instance:
UpdateAttribute msxml, "DatasourceConnection", "%MY_MACRO_NAME%"
As far as parsing values out of an XML file into temporary macros, this sample demonstrates that:
http://www.kinook.com/Forum/showthread.php?threadid=237