Execute ASP file from ASP file

T

Tomasz Ludwiniak

Hi,

I've little problem... I try to execute asp file ( which return XML file )
and use the result it in my asp script :

set xml = Server.CreateObject("MSXML2.DOMDocument")
xml.async=false
xml.load(Server.Execute("script.xml.asp"))

but it doesn;t work !

I cannot use full path to script : http://somedomain.com/script.xml.asp !

Is there any posibility to execute asp script and return result back to
asp?!

regards

Lujcon
 
R

Rob Meade

...
set xml = Server.CreateObject("MSXML2.DOMDocument")
xml.async=false
xml.load(Server.Execute("script.xml.asp"))

but it doesn;t work !

I'm probably wrong, but as you are creating an object for the XML Dom,
shouldn't the file you are trying to load with xml.load be a well-formed XML
document?

If you want the ASP to do something too - just use an include

<!--#Include File="script.asp"-->

etc...

I'm probably wrong though - haven't played a lot with XML yet...

Regards

Rob
 
T

Tomasz Ludwiniak

The file I'm trying to load is weel formated XML document
for example:

script.xml.asp:
-----------------------------------
<%
Response.ContentType="text/xml"
%>
<root>
<node>test node</node>
<%
'some vb instructions
%>
</root>
------------------------------------

Is there any possibility to execute this asp script and load result to DOM
document ?!.
When i use Server.Execute method the result will be send to client browser
( not to xml.load method )
When i use full path: xml.load("http://somedomain.com/script.xml.asp")... i
have to restart iss. I think it is because iis is going to execute
script.xml.asp after executing current script, but current script is waiting
for results from script.xml.asp....Woww... ;)

regards

Lujcon
 
B

Bob Barrows

Tomasz said:
Hi,

I've little problem... I try to execute asp file ( which return XML
file ) and use the result it in my asp script :

set xml = Server.CreateObject("MSXML2.DOMDocument")
xml.async=false
xml.load(Server.Execute("script.xml.asp"))

but it doesn;t work !

I cannot use full path to script :
http://somedomain.com/script.xml.asp !

Is there any posibility to execute asp script and return result back
to asp?!

regards

Lujcon

Use the ServerXMLHTTP object.
http://www.aspfaq.com/show.asp?id=2173

HTH,
Bob Barrows
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,900
Latest member
Nell636132

Latest Threads

Top