Copy content of Excel sheet to a text or XML file -


i have excel (2010) workbook. 1 of sheets contains 800 lines of xml tags.

it looks this:

<?xml version="1.0" encoding="utf-8" ?> <data>  <entry>    <name>john<name>   <age>58<age>  </entry>  <entry>   <name>amy<name>   <age>29<age>  </entry> </data> 

each element on seperate row/cell.

a1 = <?xml version="1.0" encoding="utf-8" ?> a2 = <data> a3 = <entry>  a4 = <name>john<name> a5 = <age>58<age> 

. . .

and on.

these aren't plain text values - content generated via concatenate across different cells in different sheet.

the formula cell a3 follows:

=concatenate(xml!a3,xml!b3,xml!c3) 

i want create vba macro outputs content of sheet xml file or text file. it's formatted xml file want content saved out.

all i'm finding online how save sheet xml that's converting data garbage since it's formatted, @ least in appearance. if makes sense.

any advice appreciated haven't worked lot vba.

thanks in advance!

sub saveasxml()     dim strfilename string     strfilename = application.getsaveasfilename(filefilter:="xml files (*.xml),*xml")     activesheet.saveas filename:=strfilename, fileformat:=xltextprinter, createbackup:=false end sub 

the fileformat has xltextprinter or else weird things quotes in string.


Comments

Popular posts from this blog

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

html - How to style widget with post count different than without post count -

url rewriting - How to redirect a http POST with urlrewritefilter -