Questions tagged [linq-to-xsd]

The LINQ to XSD technology provides .NET developers with support for typed XML programming.

The LINQ to XSD technology provides .NET developers with support for typed XML programming.

http://linqtoxsd.codeplex.com/

28 questions
59
votes
2 answers

How to create a XSD schema from a class?

I'm having a hard time with the XSD files. I'm trying to create an XSD file from a class: public enum Levels { Easy, Medium, Hard } public sealed class Configuration { public string Name { get;set; } public Levels Level { get; set; } …
Darf Zon
  • 6,268
  • 20
  • 90
  • 149
11
votes
4 answers

Is Linq2XSD Dead?

Does anyone have any updates on this since the alpha 0.2?
Jonathan Parker
  • 6,705
  • 3
  • 43
  • 54
8
votes
1 answer

How do I get LinqToXSD to properly output namespace prefix declarations?

I am experimenting creating XML data binding classes with LinqToXSD and an XML Schema containing a number of imported schemas. All of the schemas are located here. To accomplish this, I used the following root schema document:
Robert Harvey
  • 178,213
  • 47
  • 333
  • 501
7
votes
2 answers

Preserving Order In Sequence of Choices (LINQ To XSD)

Given the following XML example we could imagine a schema defining Root as containing a sequence of unbound number of choices between Type1 and Type2. I am testing out migrating…
Philip
  • 339
  • 3
  • 12
3
votes
3 answers

Using named simple-types with LINQ to XSD results in compiler error

I have an XSD containing a simple type like this: Now when I use…
TDaver
  • 7,164
  • 5
  • 47
  • 94
2
votes
1 answer

How to build an XML using XSD file in C#.Net

Hi I have an XSD file that explain what are the required fields i have to use. Using that XSD schema, I have to Build and XML Request and route to a third party service provider and once my XML request is validated, system (third-party) will return…
HaBo
  • 13,999
  • 36
  • 114
  • 206
2
votes
0 answers

With custom WSDL and a referenced schema, why isn't the return Xml from my SOAP method serialized from the objects correctly?

After reading this article: Improve Web Service Interoperability with XML Message Design I decided to have a go at importing our existing message design schema into the WSDL for our new SOAP service. This is all in VS2008 and .NET 3.5, Altova XMLSpy…
RoboJ1M
  • 1,590
  • 2
  • 27
  • 34
2
votes
0 answers

Linq to XSD for Silverlight

It appears that the LINQ to XSD project has some dependencies on types that are not available in Silverlight, such as System.Xml.Schema.XmlSchemaType. Considering that, I know it would take a significant amount of work to get LINQ to XSD to work in…
Andrew Garrison
  • 6,977
  • 11
  • 50
  • 77
2
votes
2 answers

How do you tell the C# compiler that a symbol is a type and not a variable when they share the same name?

When you have a local variable named the same as a type, is there any way to tell the compiler that the symbol you have given is a type or a variable? For instance consider (and ignore all type return errors): public class sometype { public static…
Matt Mitchell
  • 40,943
  • 35
  • 118
  • 185
2
votes
1 answer

Using C# and XDocument, how to I add xsi attributes into some Xml?

I need to fix Linq to Xsd so that it correctly handles arrays of elements of a global abstract complex type, of which there are multiple derived non-abstract types. It doesn't add the xsi namespace or mark up elements with their derived types. But…
RoboJ1M
  • 1,590
  • 2
  • 27
  • 34
2
votes
1 answer

Experiences with LINQ2xsd?

I am looking for more advanced alternatives to xsd.exe. I am just about to start a fairly simple project and decided to try using LINQ2XSD. The project has now been released as open source to CodePlex. I'm just wondering how many people have…
Simon_Weaver
  • 140,023
  • 84
  • 646
  • 689
2
votes
1 answer

Using LinqToXSD, how to get the objects in a xml without casting?

I'm using this technology to manage my XML files as Databases. When I do this, normally I created the classes in a library and using XSD.exe I can get my XSD. Then, with LinqToXSD and my new XSD generated, I can access to the data. This is my first…
Darf Zon
  • 6,268
  • 20
  • 90
  • 149
1
vote
0 answers

LinqToXsd Serialization gives duplicate (nested) root element

I have a number of XSD's which have to be used as requests for web services. When I serialize the request to a string (or file), then the root element is always repeated as an xml element. Why is this? How can I prevent this? I use LinqToXsd (nuget…
Fastolph
  • 11
  • 3
1
vote
1 answer

Simpler Linq to XML queries with the DLR

I have a question regarding Linq to XML queries and how we could possibly make them more readable using the new dynamic keyword. At the moment I am writing things like: var result = from p in xdoc.Elements("product") where…
Xavier Poinas
  • 19,377
  • 14
  • 63
  • 95
1
vote
2 answers

LINQ to XSD in Visual Studio 2010 Beta2

I've been looking around and I was wondering if this is available in VS10 beta2. So far all I've seen is the Linq to XSD alpha 0.2 preview that works for VS 2008
Will
  • 1,622
  • 4
  • 25
  • 39
1
2