My initial reaction is that you would have to create your own ActiveX control (pluggin) for doing that, and place it on your ASP page. The control would then be downloaded and run on the client, giving you access to the clients entire machine.
Now, there are security implications associated with this approach, and the control must be implement certain "safe for scripting" type COM interfaces.
Such a control could be written in VB 6.0, as an OCX.
XML has a built in HTTPRequest to access XML document anywhere here is some code that will get an XML document and display the contents.
<%option explicit%>
<%
on error resume next
' Set the source and stylesheet locations here
dim sourceCategory
dim sourceFile
dim styleFile
dim source
dim style
dim result
sourceCategory = Request.QueryString("c"
If sourceCategory = "" Then
sourceCategory = "Videogame news"
End If
' Load the XML
Set source = Server.CreateObject("Msxml2.DOMDocument.3.0"
source.async = false
source.setProperty "ServerHTTPRequest", true
source.load sourceFile
' Load the XSL
Set style = Server.CreateObject("Msxml2.DOMDocument.3.0"
style.async = false
style.setProperty "ServerHTTPRequest", true
style.load styleFile
'Check for errors - Display errors or perform the transformation and output the results.
If source.parseError.errorCode Then
result = "source error: " & source.parseError & " --"
Else
If style.parseError.errorCode Then
result = "style error " & style.parseError & "//-->"
Else
result = source.transformNode(style)
End If
End If
Response.Write result
if isObject(source) then set source = nothing
if isObject(style) then set style = nothing
if err.number <> 0 then
response.write err.Description
end if
%>
you should be able to cut and paste this code and run it,
but you can replace "sourceFile" and "styleFile" with your own, for personal testing. Megalene
If you crap it will stink!
Megalene, will what you propose work client-side, for XML docs stored on the client workstation? Or, is it really just a server-side, ASP solution that can read XML files from any-old HTTP location (URL)?
Is this for an intranet? If so you could use your network path instead of the http path of the XML document. After testing here at work locally I was able to view xml documents hosted on another workstation. Megalene
If you crap it will stink!
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.