public static XmlSchemaComplexType GetDataTableSchema(XmlSchemaSet schemaSet)
{
XmlSchemaComplexType type = new XmlSchemaComplexType();
XmlSchemaSequence sequence = new XmlSchemaSequence();
XmlSchemaAny any = new XmlSchemaAny();
any.Namespace = XmlSchema.Namespace;
any.MinOccurs = 0;
any.MaxOccurs = decimal.MaxValue;
any.ProcessContents = XmlSchemaContentProcessing.Lax;
sequence.Items.Add(any);
any = new XmlSchemaAny();
any.Namespace = Keywords.DFFNS;
any.MinOccurs = 1; // when recognizing WSDL - MinOccurs="0" denotes DataSet, a MinOccurs="1" for DataTable
any.ProcessContents = XmlSchemaContentProcessing.Lax;
sequence.Items.Add(any);
type.Particle = sequence;
return type;
}