Fix for bug 9811: When web method returns DataTable the method generated in proxy...
[mono.git] / mcs / class / System.Data / System.Data / DataTable.cs
index 8b5c38772ad35589d7235bb3997203322bdaba2f..c799bf27949e64ee005a4110dd0c7e12dea053da 100644 (file)
@@ -2036,7 +2036,21 @@ namespace System.Data {
 \r
                public static XmlSchemaComplexType GetDataTableSchema (XmlSchemaSet schemaSet)\r
                {\r
-                       return new XmlSchemaComplexType ();\r
+                       XmlSchemaComplexType result = new XmlSchemaComplexType ();\r
+                       XmlSchemaSequence seq = new XmlSchemaSequence ();\r
+                       XmlSchemaAny any = new XmlSchemaAny ();\r
+                       any.Namespace = XmlConstants.SchemaNamespace;\r
+                       any.MinOccurs = 0;\r
+                       any.MaxOccursString = "unbounded";\r
+                       any.ProcessContents = XmlSchemaContentProcessing.Lax;\r
+                       seq.Items.Add (any);\r
+                       any = new XmlSchemaAny ();\r
+                       any.Namespace = XmlConstants.DiffgrNamespace;\r
+                       any.MinOccurs = 0;\r
+                       any.ProcessContents = XmlSchemaContentProcessing.Lax;\r
+                       seq.Items.Add (any);\r
+                       result.Particle = seq;\r
+                       return result;\r
                }\r
 \r
                public XmlReadMode ReadXml (Stream stream)\r