Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Update an XML file, then save it

Status
Not open for further replies.

RowanDai

Technical User
Mar 26, 2003
4
AU
Hi

I'm new to ASP, but have been told that I can use it to easily update and save a file to disk.

I currently use XML and XSL files, and load them as a XMLDOM objects as per:

<%
'Load XML
set xml = Server.CreateObject(&quot;Microsoft.XMLDOM&quot;)
xml.async = false
xml.load(Server.MapPath(&quot;tblMasterFile.xml&quot;))
'Load XSL
set xsl = Server.CreateObject(&quot;Microsoft.XMLDOM&quot;)
xsl.async = false
xsl.load(Server.MapPath(&quot;SetIgnoreFlags.xsl&quot;))
'Transform file
Response.Write(xml.transformNode(xsl))
%>

What I want the user to do is update the data on the screen, and I can then save the updated file direct to disk without the need for a (CGI) executable to do the write for me.

1) Is it possible?
2) Is there a simple way to do it using the DOM object, or do I have to use fso?
3) If I do have to use fso, how do I translate my xml file into an fso?

Many thanks
Rowan
 
use save method of xml DOM object
xml.save [&quot;XmlFileNameWithPathURL&quot;]
 
Many Thanks
Appreciated. I'm still having problems, but it turns out my ASP access rights are not set up properly, and won't let me save. I'll fix this first.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top