473,386 Members | 1,715 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

How to supply XMLDocument with a user and passord?

Hi,

I'm rewriting an old VBS-script to VB.NET.
The program fetches XML from an .asp page and transformes the data according
to a .xsl file.
To fetch the data in the old program I used the following code:
Set oXMLHTTP = CreateObject("MSXML2.ServerXMLHTTP.4.0")

'Set the timeouts
oXMLHTTP.setTimeouts toResolve, toConnect, toSend, toReceive

' Use the Microsoft serverXMLHTTP object to retrieve the XML from the
remote server (ReturnXML program)
oXMLHTTP.Open "GET", sURLtoReturnXML & sXMLQuery, false,
"UserName","Password"
oXMLHTTP.Send("")

'The data has been fetched and after that the data will be transformed.
The way I thought of doing it in the new program is as follows:
Dim oXmlDoc As XmlDocument = New XmlDocument
Dim oXSLTransForm As Xsl.XslTransform = New Xsl.XslTransform
Dim oXmlTextWriter As XmlTextWriter = New
XmlTextWriter(sOutputFileName, System.Text.Encoding.UTF8)

oXmlDoc.Load(stCommon_settings.sXMLreturn)
oXSLTransForm.Load(stCommon_settings.sXSLTransform ationFile)
oXSLTransForm.Transform(oXmlDoc, Nothing, oXmlTextWriter, Nothing)
oXmlTextWriter.Close()

It works like a charm locally, but the problem is that on the server I have
to be authenticated like I did in the old example with
MSXML2.ServerXMLHTTP.4.0.
How can I perform this with the new program?

Best regards Dan
Nov 22 '05 #1
0 1145

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: brad | last post by:
I have an XMLDocument that my web page downloads and manipulates as a response to user input. I have lots of JavaScript that acts as a controller between my view (html) and my model (xml). That...
0
by: Danne | last post by:
Hi, I'm rewriting an old VBS-script to VB.NET. The program fetches XML from an .asp page and transformes the data according to a .xsl file. To fetch the data in the old program I used the...
8
by: Philippe C. Martin | last post by:
Hi, I am attempting to write a linux logon manager with python. Can python access login APIs (which module ?) or do I need to write a wrapper ? Regards, Philippe
0
by: KathyB | last post by:
Hi, I'm creating my first (so please be patient) web app in asp.net. I have a mainframe.aspx and within that a leftframe.aspx and rightframe.aspx. The leftframe holds some variables and has a...
5
by: KathyB | last post by:
If someone could just explain this to me...I just don't get it! I have an aspx page where I retrieve several session variables and use xmlDocument to transform xml file with xsl file into an...
1
by: Zeng | last post by:
Hello, I have profiled my code, and the current performance bottleneck is this routine. It gets called 7400 times to do some intensive calculations when a user uses the feature. The xmlText...
4
by: Jesper Stocholm | last post by:
I have a database class that maintains data about customers i my system. The basic XML for this looks like: <Chunk> <Vendor> <Database/> </Vendor> </Chunk> When a user is to be registrered...
5
by: Bob P | last post by:
I have an example below that is not working correctly. I have a web application that passes a System.Xml.XmlDocument object "oInputDoc" around to functions byval. I do not want the "oInputDoc"...
4
by: kimso.zhao | last post by:
Hi All, I need a function that when user types a password in the console, the password should be invisible (e.g. display nothing or display "*" instead). Just as you can see when you login a...
1
by: Tom | last post by:
I am on .NET 2.0 and am trying to serialize an object to an XmlDocument (or a string which I can then create an XmlDocument from). What I have so far is (User is my class); XmlSerializer x =...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.