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 649739
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T21:58:36+00:00 2026-05-13T21:58:36+00:00

I’m trying to do some work with C# and XML in a cross-platform app

  • 0

I’m trying to do some work with C# and XML in a cross-platform app (most development is in MonoDevelop on Linux, but most users will end up using the WinForms front-end that I make in Visual Studio). Mono is behaving as I’d expect, but .Net isn’t and so I’m looking for options and alternatives.

The schemas have various optional elements followed by an “xs:any” element. This works perfectly fine in Mono, but not in Microsoft’s .Net as it complains that the occurrence of the optional element is ambiguous between its actual definition in the schema and “xs:any”. From a bit of reading up, it appears to be a problem that was resolved in later versions of W3C’s Schema definition. Obviously Mono has been kept up to date, but Microsoft are lagging.

The options I can see are:

1) Use RelaxNG – unfortunately the link from the main site to the C# implementation is broken. It is part of Mono, but that isn’t much help when running on MS’ .Net. The only way I can see to do it is to duplicate and rebuild Mono’s version as my own DLL

2) Use Schematron – I found it as a suggestion on making backward and forward compatible XML, but it seems more like a format validator than a ‘standard’ schema language. I’m not quite sure where the implementation is – all I can find is a command-line validator.

3) Make sure that the MS .Net implementation uses the updated schema standard that Mono uses as well – I don’t even know if this is possible.

4) Stick with ugly schemas and put “xs:any” within an optional “extensions” element – it nests it for no good reason other than the official .Net framework doesn’t get confused, but it works.

The code is aimed at .Net 2.0, but I’ve got 3.5 installed on my machine. I’m also working with Mono 2.4, MonoDevelop 2.2 and Visual Studio Express 2005.

Are any of 1-3 possible, or am I stuck with 4?

Thanks.

  • 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-13T21:58:37+00:00Added an answer on May 13, 2026 at 9:58 pm

    You may be able to work around the ambiguity problem by setting the XmlSchemaSet.CompilationSettings.EnableUpaCheck to false. UPA stands for the Unique Particle Attribution requirement of the XML Schema standard that you referenced.

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

Sidebar

Related Questions

I am trying to understand how to use SyndicationItem to display feed which is
Basically, what I'm trying to create is a page of div tags, each has
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have just tried to save a simple *.rtf file with some websites and
I want to count how many characters a certain string has in PHP, but
For some reason, after submitting a string like this Jack’s Spindle from a text
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I am trying to render a haml file in a javascript response like so:
I have a French site that I want to parse, but am running into
In my XML file chapters tag has more chapter tag.i need to display chapters

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.