Loading XmlDocument with a file on network?

Can you load an XmlDocument with a file located on a network share?  I thought maybe the XmlResolver could be used

XmlUrlResolver resolver = new XmlUrlResolver()
resolver.Credentials = CredentialCache.DefaultCredentials
// Create and load the XmlDocument
XmlDocument doc = new XmlDocument()
doc.XmlResolver = resolver;  // Set the resolver



But I get: "Logon failure: unknown user name or bad password"
anonymous (74722)
4/5/2004 1:46:05 PM
dotnet.xml 7266 articles. 0 followers. Follow

1 Replies

Similar Articles

[PageSpeed] 42

The problem is probably that the account that your application is running
under does not have access to the network share. Are you trying to read the
XML document from a desktop app or a Windows service (like ASP.NET for

Christoph Schittko [MVP]
Software Architect, .NET Mentor

"Dave" <anonymous@discussions.microsoft.com> wrote in message
> Can you load an XmlDocument with a file located on a network share?  I
thought maybe the XmlResolver could be used.
> XmlUrlResolver resolver = new XmlUrlResolver();
> resolver.Credentials = CredentialCache.DefaultCredentials;
> // Create and load the XmlDocument.
> XmlDocument doc = new XmlDocument();
> doc.XmlResolver = resolver;  // Set the resolver.
> doc.Load(@"\\devsrv\profiles\0004.xml");
> OR...
> doc.Load("//devsrv/profiles/0004.xml");
> But I get: "Logon failure: unknown user name or bad password"

4/6/2004 7:23:25 AM

Similar Artilces:

The File As field is empty, do you want to save this file. Outlo.
I created a contact folder with my own field names. After entering the data I want when I move to the next row of data I get this error message, "The File As field is empty. You may have not entered a name or company. Do you want to save this contact with an empty File As field?" How do I correct this error? Thanks -- Terry It's a warning, not an error. Sounds like you need to set up your data entry view so you can enter the Full Name or Company, which Outlook will automatically use to generate a File As name. -- Sue Mosher, Outlook MVP Author of Microsoft Out...

Read File Properties
How would I read the file version properties of a standard DLL? In particular I need the company name property from VISA32.dll. VISA32.dll is a standardized Virtual Instrumentation Software Architecture function library that is published by several manufacturers. I need the manufacturer name of the *installed* library. David "David Youngblood" <dwy@flash.net> wrote in message news:%23oPqMidaKHA.4668@TK2MSFTNGP06.phx.gbl... > How would I read the file version properties of a standard DLL? In > particular I need the company name property from VISA3...

loading network card information ...error provider load failure
This is a multi-part message in MIME format. ------=_NextPart_000_000F_01CA7D92.03F9F310 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi there, I get "loading network card information ...error provider load failure" = when I go and use systeminfo.exe . How can I fix this? Thanks, Gordon ------=_NextPart_000_000F_01CA7D92.03F9F310 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN&qu...

OWA (Not Loading)
Does anyone know of any issues with Satellite Service and the right side of OWA not loading. The left side loads but the user cannot see anything on the right. OWA works from any other connection. Thanks, KG ...

File properties shortcut key
Hi Is there some key combination that enables the user to quickly jump to file properties in excel 2007. Kind regards IgorM hi for your question's answer maybe look at this link, http://www.createthefuture.com/Excel_tech_tips "IgorM" wrote: > Hi > > Is there some key combination that enables the user to quickly jump to file > properties in excel 2007. > > Kind regards > > IgorM > > > ASAP utilities have nice macro that shows you all the info about the file. And it is free for home use! http://www.asap-utilities.com/ Shows...

SOS,how to load a invalid or damaged .gif file to create Image Object.
hi everyone. my question is this:how to load a .gif image file that is invalid or damaged image format? Notice,I want to load the invalid damaged image file to operate it. my code is below,but all of they are not correct. -------- 1.Image.FromFile(fileName);load from a file directly,it throws a OutOfMemoryException.In msdn,it's mean the file is a invalid image format. 2.Image.FromStream(stream);load from stream,it throws a ArgumentException. -------- ps:IE and Google Picasa can load and display the damaged .gif file correct. Or there is any other methods to operate the i...

Why Excel file doesn't open by double click.
Excel files that are stored in my HD doesn't open by double click. It just open Excel program but do not open the file. Pls note, I can open any excel file from File Menu, then Opne. But can't opne it by double click. Using Windows XP with Office XP / Excell 2002. Pls suggest me what to do. Thanks. Hi Siraj Tools>Options>General uncheck "Ignore other Applications" Exit Excel and try again If this doesn't work try to re-register Excel Close Excel first and On the Windows Taskbar 1 ) Start>Run "excel.exe /unregserver"(no quotes)>OK. 2) Start...

Error loading CRM 3.0 Client with Outlook
I receive error message "An error occurred loading Microsoft CRM Functionality" when starting Outlook with CRM 3.0 client installed. I have uninstalled CRM, Office, and cleaned the register using Register Mechanic. I am now getting the same error with an event error "A problem occurred initializing Microsoft CRM COM interopt". Anyone have any ideas? Thanks. I have the exact same issue has anyone found a solution to this? I am running all avialable updates on both Office 2003 and XP Pro, I DO NOT have the Business Contact Manager for Outlook installed. "rtop...

docx files have words merged together
Version: 2008 Operating System: Mac OS X 10.5 (Leopard) Processor: intel Recently switched to Office 2008 from 2004. Files that I save in docx on the Mac have words randomly merged together (example, "what if" might become "whatif") when opened in Office 2007 on a PC or in other programs on the Mac (Open Office, for example) but not when opened in 2008. This problem does not happen when I save the same file as a doc. The whole reason I upgraded from 2004 was so I'd be compatible with new document format so this is very frustrating. Has anyone else seen this problem, or...

Importing older .pst file into Outlook 2003?
I am getting an error message "file not personal folders file" when trying to import a .pst file that was created in version 2000 into Outlook 2003. Tried converting non-Unicode to Unicode but that did not work. Need help please. First: importing is never the correct way to transfer Outlook data.You just open the PST file in Outlook and either copy what you need from it or configure it as your default data file. Second: Post some useful information. Basic information would include how you created and transferred this PST file. "Tried converting from non-Unicode to Unico...

personal files lost during crash
My Outlook crashed Friday. I managed to reopen with brand new (empty) Inbox/Sent/Outbox/Contacts etc. I also ran the Inbox Repair tool, which did not work (an error message popped up after 4 of 8 phases saying could not complete scan). I would like to retrieve my old folders, emails, calendar items, contacts if possible. Can anyone tell me the process to do this? Thank you. >I also ran the >Inbox Repair tool, which did not work (an error message >popped up after 4 of 8 phases saying could not complete >scan). If the Inbox Repait Tool can't make sense out of the old PST,...

Automatic, conditional chart creation from separate files [Excel 2007]
I have a number of separate files (Excel 2007). Each file contains several sheets with test results of a few students. The students (the same, all the time) are evaluated each month using the same test, and each month a new sheet is created for each of them. For example: Workbook 1: Worksheet A (John), Worksheet B (Jennifer), Worksheet C (Anna) Workbook 2 (a month later): Worksheet A (Jennifer), Worksheet B (John), Worksheet C (Anna) I`d like to create a separate file with charts depicting the mean results for each student. The chart would retrieve data automatically from every file s...

loading web application project suddonly takes 5 mintues and says "Contacting server to open Web project.." wile it takes 5 minutes to load. how to fix? i tried reregistering asp.net and iisreset. no
loading web application project suddonly takes 5 mintues and says "Contacting server to open Web project.." wile it takes 5 minutes to load. how to fix? i tried reregistering asp.net and iisreset. no progres. ...

What do I load ?
Hello. I'm trying to develop a web comsuming client using VS.NET 2003(VB), .NET Framework 1.1.4322, ASP.NET 1.1.4322, WSE2.0 on a WinXP Pro Sp2 comuter. If i comsume this web service: https://xatanet.net/xatanetwebservice/tripexportservice.asmx and do this operation: RetrieveArchivedTrips using: Dim strDate As Date = "2006-04-01" Dim endDate As Date = "2006-04-28" proxy.RetrieveArchivedTrips(strDate, endDate) What do I load when i use the following statements in my program: Dim doc as XmlDocument = new XmlDocument() doc.Load() Any...

Please make Plus! CD Label Maker use Microsoft Publisher Files
Plus! CD Label Maker and Microsoft Publisher are both Microsoft products yet Plus! CD Label Maker can't use designs made in Publisher and Publisher can only print to the Avery 8931 CD/DVD label. ---------------- This post is a suggestion for Microsoft, and Microsoft responds to the suggestions with the most votes. To vote for this suggestion, click the "I Agree" button in the message pane. If you do not see the button, follow this link to open the suggestion in the Microsoft Web-based Newsreader and then click "I Agree" in the message pane. http://www.microsof...

Macros don't work when file name changes
I created a workbook with many macros using the simple "record macro" tool. This fiel was saved in *.XLS format. It is intended to be a master fille and when you fill it out as a form you re-save it with a new name. the problem I am running into is that after I re-save it wit a new name the Macros won't work properly. I get an error message and when I click to run the debugger the macro lists the original workbook name. How do I fix this so that the macros work regardless of file name? Without seeing the code, my guess is that the macro recorder put explicit file...

Outlook 2007 using IMAP settings: Deleted files are disappearing
I am using Outlook 2007 (using IMAP settings) and Windows 7. When I delete an e-mail in Outlook, a line appears through the message and it disappears after a few seconds but the message does not get moved to the deleted (Outlook and IMAP) files folder. I have checked for the deleted message in my IMAP deleted files and/or trash folder via webmail as well as in the Outlook deleted folder. I have unchecked the auto archive and the option to purge the folder on exiting in Outlook. Can anyone tell me where these files have gone? Could it be something in my settings? Is this a...

Debug image fails to load.
Hi, I created an OS design with KITL, Kernel debugger enabled in Debug mode. But when i try to load the image to the CEPC it fails to boot. I am attaching the log here. ------ SERIAL PORT LOG starts ----------- Microsoft Windows CE Ethernet Bootloader Common Library Version 1.0 Built Dec 9 2002 18:35:13 Copyright (c) 2000-2001 Microsoft Corporation Microsoft Windows CE Ethernet Bootloader 3.3 for CE/PC (Feb 6 2003) Boot Args @ 0x1F136 and ucLoaderFlags is 1 PCI Device Configurations (3 PCI bus(es) present)... ======================================================== Bus, Devi...

Exporting messages from a PST file
Hi, I have a need to export several hundred mail messages currently in a ..PST file to any sensible text format that I can move to a linux machine. There is no need to operate the result on any email program, but I am doing this to archive the messages, so I can read them if I need to. I use Microsoft Office Outlook 2003 (11.5608.5606) in a corporate setting, on Windows 2000. Last time I did this, I chose "Tab separated values (DOS)". The trouble with this is that I only get Subject, Body:, From:, To:, CC:, BCC:, and the totally irrelevant fields of Billing Information, Categori...

Click on a link and a picture loads in cell depending on which link you have clicked
Hello If I have five links in cells A1:A5 with peoples names. How can get... e.g. If I click on Bill in A2 then a picture of Bill loads in cell D1 an then click Mark and a picture of Mark loads in D1. Thanks in advanc -- Message posted from http://www.ExcelForum.com I'm not sure what you mean by link in A1 through A5, but I'd try it this way: Put all 5 pictures on the worksheet and position them where you want them. Name them to match the values in A1:A5. Select the picture for Bill and then type Bill in the name box (to the left of the formulabar) and hit enter. After all 5...

Excel cannot access my file and the message is (Excel cannot access "Filename.xls". The Document may be read-only or encrypted), after I press Ok showing other message (cannot access 'file number'.) How are you opening the file? If you are clicking on the list of the last n used AND you've changed the folder in which the file is kept, it won't find it I would suggest you try to open the file by double clicking on the file name from within Windows Explorer. If it opens OK you have a pathing problem. If it still doesn't open the problem is with the file itse...

Saving files to memory stick
Hi, I am wanting to save a lot of individual files from a web based program to my memory stick, once I click on save they are in a Microsoft Word format - I then have to select my memory stick before I can then save. Is there a way of making my memory stick the default save location so I don't have to select it every time? Thanks Never save or write files directly to removable media. You risk ending up with corrupt files. -- JoAnn Paules MVP Microsoft [Publisher] Tech Editor for "Microsoft Publisher 2007 For Dummies" "Jon" <Jon@discussions....

PST file problems
I have copied my outlook.pst and archive.pst files from my Win98SE/Outlook2000 to CD. I then did a clean install of WinXP on the system. After installing Office2K, I transferred the files from the CD to the dexktop and proceeded to open Outlook and tried to open/import the PST files back to my new version of Outlook2000. First I got the common "properties for this information must be defined prior to use" messages and ".is not a personal folders file". So I checked the files to assure that the files weren't "read-only". They weren't. Still couldn'...

Loading Error
Hi I am logged on as Domain administrator and have installed Office 2000 twice over.. I am getting the following error, and I have put it into Microsoft Support but it comes up with nothing. The error is "Unknown Error 0xAF54011D You Do not have permission to log on" any Ideas thanks It helps telling where you get this error and where you are trying to connect to. -- Roady [MVP] www.howto-outlook.com Tips of the month: -Setting Permissions on a Mailbox -Create an Office XP CD slipstreamed with Service Pack 3 ----- "News" <sasa@sdfad.com> wrote in message ...

Sharing an .OST file
I have a group email mailbox set up that several people access. It resides on our server, which limits the amount of space available and thus, limiting the amount of messages that can be kept in it. I would like to set up a .PST or .OST file on a shared drive on our network that everyone can access. I want everyone to be able to access the inbox, sent folder, etc without any limitations, and perfectly in sync. Am I on the right track thinking about an .OST file on a shared drive? Does anyone know how this can be done or if it's even possible? Thanks AKKGFK <nospam@dejazzd.com...