Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7037061
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T01:29:54+00:00 2026-05-28T01:29:54+00:00

REVISED QUESTION I have revised the original question (as seen below) so that I

  • 0

REVISED QUESTION
I have revised the original question (as seen below) so that I can mark a part of the problem as answered. So here goes:
I have built a tool to import sales orders from customer stores (magento) for integration into our legacy order processing system. I have five stores to import from. One of them has HTTP Authentication set on its store and my API Login fails because of this. How do I get past this?

ORIGINAL QUESTION (Title: Importing Sales Orders from Magento Using C#: There is an error in XML document (2, 372)):

I have built a tool to import sales orders from customer stores (magento) for integration into our legacy order processing system. I have five stores to import from. Three work fine.

  • PROBLEM 1: The fourth store throws up this exception upon executing
    the salesOrderList() call:

    A first chance exception of type ‘System.InvalidOperationException’ occurred in System.Xml.dll

    There is an error in XML document (2, 372).

    The login succeeds, I am able to enumerate attribute values, etc.
    But I am unable to run the salesOrderList() function with any
    filter (and null too). It would be great if someone has experience
    with this and can point me in the right direction.

  • PROBLEM 2: The fifth store has HTTP authorization to access its
    main magento page. I have only worked with API User Name and API Key.
    But it looks like I have to cross the HTTP Authorization hurdle to
    get to the API login stage. The Login() function of magento web
    service takes only the API User Name and API Key. Not sure how to
    handle the extra layer of HTTP Authentication. Can anyone help?
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T01:29:55+00:00Added an answer on May 28, 2026 at 1:29 am

    This will happen often, you just got lucky and it’s the first time you’re having this problem.

    What you can do is using fiddler verify why are you receiving a bad XML format, as .NET only parses it and sees that Magento did not sent anything that is worth of trying as it’s wrongly created.

    Normally you end up parsing the raw responses from Magento as it’s way safer, or use XmlRpc calls.

    But for now, check as you have more than one to test, the difference between the responses in fiddler.

    Regarding your authentication, you need to ask the host for the credentials, and add them to your request as a new NetworkCredentials object in the correct property of your service object.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

REVISED QUESTION (SEE BELOW FOR ORIGINAL): Here is an example of a simple ajax
Edit: original question below, but I revise it now that I have some code
REVISED QUESTION : We have tracked this down to a custom add to cart
REVISED QUESTION: have an xml document, i wish to change the qty of a
Basic question, but I can't figure it out...I have a label with an accelerator
Edit: The original premise of the question was incorrect so revised the question: Basically
OLD QUESTION (Already answered by Mark - The answer is to use getTag()): Let's
Update: Here's a similar question Suppose I have a DataTable with a few thousand
Okay this is a revised question from earlier today, I have included code to
I have a question about functional dependencies. My understanding was that, for example, if

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.