title: ContractException when serialize my custom datatable
body: <p>I got error when try execute this wcf code</p>
  
  <blockquote>
    <p>An ExceptionDetail, likely created by IncludeExceptionDetailInFaults=true, whose value is:
    System.InvalidOperationException: An exception was thrown in a call to a WSDL export extension: System.ServiceModel.Description.DataContractSerializerOperationBehavior
     contract: <a href="http://tempuri.org/:IService1" rel="nofollow">http://tempuri.org/:IService1</a> ----> System.Runtime.Serialization.InvalidDataContractException: Method 'MyClassLibrary.MyDataTable.GetSchema()' must return a schema with a valid Id.
       at System.Runtime.Serialization.SchemaExporter.InvokeGetSchemaMethod(Type clrType, XmlSchemaSet schemas, XmlQualifiedName stableName)
       at System.Runtime.Serialization.SchemaExporter.ExportXmlDataContract(XmlDataContract dataContract)
       at System.Runtime.Serialization.SchemaExporter.ExportDataContract(DataContract dataContract)
       at System.Runtime.Serialization.SchemaExporter.Export()
       at System.Runtime.Serialization.XsdDataContractExporter.Export()
       at System.Runtime.Serialization.XsdDataContractExporter.Export(Type type)
       at System.ServiceModel.Description.MessageContractExporter.ExportType(Type type, String partName, String operationName, XmlSchemaType&amp; xsdType)
       at System.ServiceModel.Description.DataContractSerializerMessageContractExporter.ExportBody(Int32 messageIndex, Object state)
       at System.ServiceModel.Description.MessageContractExporter.ExportMessage(Int32 messageIndex, Object state)
    ....
    ...
    ....</p>
  </blockquote>
  
  <p>Custom datatable</p>
  
  <pre><code>Public Class MyDataTable
      Inherits DataTable
  
      Public Sub New()
      End Sub
  
   End Class
  </code></pre>
  
  <p>My WCF Interface</p>
  
  <pre><code> &lt;ServiceContract()&gt; _
   Public Interface IService1
     &lt;OperationContract()&gt; _
     Function TestDatatable(ByVal MyDT As MyDataTable) As Boolean
  End Interface
  </code></pre>
  
  <p>Implementation</p>
  
  <pre><code>Public Class Service1
    Implements IService1
  
      Public Function TestDatatable(ByVal MyDT As MyClassLibrary.MyDataTable) As Boolean Implements IService1.TestDatatable
  
            Return MyDT.TableName = "MyTable"
  
       End Function
  End Class
  </code></pre>
  
  <p>Note: When just using datatable its ok but not my custom datatable.</p>
  
  <p>What need to be added do I can serialize my custom datatable.
  I able to serialize my other object but not this class.</p>