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

  • Home
  • SEARCH
  • 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 5949103
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T17:12:07+00:00 2026-05-22T17:12:07+00:00

I have Serialized Instance Data from a 3rd party application, it is in XML

  • 0

I have Serialized Instance Data from a 3rd party application, it is in XML and I want to load it into an object and work with it.

I generated a XSD off the the XML and it works great. The XML represents the state of a form the user filled out. The first time I generated the XSD, I hadn’t filled out the whole form -the form instance being what is serialized. I went back and filled out the whole form, so that all the controls I need are present, and created a new XSD, and used XSD2Code to generate a new class.

Question is, if I don’t know what all of the serialization looks like for the form itself – is my approach flawed from the beginning or is it the best that I can do?

Is sticking interfaces on the Controls I need on the generated classes a good way to mitigate changes in the characteristics of the underlying instance data?

I know now that I at least need to be able to work with certain things in the form and they are all present. If in the future more stuff is added to the form, I can regenerate the XSD and build on already present implementation.

Is this a sound approach, in that I will create a partial class which specifies on the generated classes that they at least implement the things I need?

Is there anything you can foresee that will challenge the code that I write that works with these interfaced types in the instance class?

Is there a way to have my de-serialization methods, not break if theres stuff that it isn’t expecting?

  • 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-22T17:12:07+00:00Added an answer on May 22, 2026 at 5:12 pm

    Ignorance is generally not a best practice.

    If they are sending you the XML, then don’t they know what shape it is? Don’t they have an XSD?

    At the very least, can’t they provide you with a document on the format?

    In any case, you need an XSD that represents what they will actually be sending you, so you can generate classes that match what you will actually receive. It’s even possible that you’ll find that the XML structure they are sending you does not match any possible set of classes, and that you will need to deserialize “manually”.

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

Sidebar

Related Questions

I have a class which is serialized to and from an XML file when
I have a pretty sizeable object graph that I have serialized to a file
I have an object graph serialized to xaml. A rough sample of what it
I have an object that is mapped to a cookie as a serialized base-64
I have an application that I'm converting to Symfony/Doctrine. It currently stores a serialized
I would like to serialize an instance of JS object from the Server-side to
Please provide scenarios/conditions those fail during deserialization when a class & serialized object have
XML Serialization from MSDN : Serializes and deserializes objects into and from XML documents.
I have a set of classes I wish to serialize the data from. There
In working with MS Expression Blend, you can import sample data from an XML

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.