Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
XSD & generated dataset - Base class
Message
De
21/11/2004 16:53:54
 
Information générale
Forum:
ASP.NET
Catégorie:
ADO.NET
Divers
Thread ID:
00963350
Message ID:
00963354
Vues:
10
Stephane,

You don't want to mess with the generated code. I recommend using an Interface and then create a sub-class from your typed DataSet. Something like this:
public interface IMyDataSet
{
  void MyDataSetMethod();
}
public class Ar_CustMaster_DataSet : Ar_CustMaster, IMyDataSet
{
  public void MyDataSetMethod()
  {
    // whatever code
  }
}
~~Bonnie


>I am trying to figure out how i can make the generated typed datasets from VS 2003 us my dataSet base class instead of the Syste,.Data.DataSet base class.
>
>The genarated code produce this:
>
>    public class AR_CustMaster : DataSet {}
>
>
>I need the dataset generator to produce this:
>
>    public class AR_CustMaster : MyDataSet {}
>
>
>I know i can go in the generated .cs file and manually change it but as soon as the dataset is regenerated, my changes are lost.
>
>Is there any way to make the change permanent ?
>
>Thanks.
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform