C est quoi DataRowBuilder

Résolu
ProphetKy Messages postés 100 Date d'inscription samedi 11 janvier 2003 Statut Membre Dernière intervention 16 juin 2006 - 30 nov. 2005 à 09:07
cs_vpoyo Messages postés 363 Date d'inscription vendredi 14 février 2003 Statut Membre Dernière intervention 20 avril 2010 - 30 nov. 2005 à 09:59
Hello,

J'utilise un dataset typé créé depuis ma DB.
J'aurais aimé travaillé avec les classes qu'il m'a généré automatiquemt pour rajouter une ligne dans une table.

Et la je sais pas trop comment faire ...



,
----

Dim dr As DataRowBuilder = New DataRowBuilder(DS_CV.TabGeneralInfoDataTable, 1, 1)
Dim rowInf As New DS_CV.TabGeneralInfoRow(dr)

rowInf.BornDate = MyGeneralInfo.BornDate
rowInf.Name = MyGeneralInfo.Name
rowInf.Nationality = MyGeneralInfo.Nationality
rowInf.Profile = MyGeneralInfo.Profile

Il me fait une erreur sur le new en disant :

System.Data.DataRowBuilder.Private Sub New(table As System.Data.DataTable, rowID As Integer, record As Integer)' is not accessible in this context because it is 'Private'.

Merci

1 réponse

cs_vpoyo Messages postés 363 Date d'inscription vendredi 14 février 2003 Statut Membre Dernière intervention 20 avril 2010 6
30 nov. 2005 à 09:59
salut,http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfsystemdatadatarowbuilderclasstopic.asp

ca dit : "This type supports the .NET Framework infrastructure and is not intended to be used directly from your code."
ce qui signifie : tu n'es pas censé utiliser cette classe, d'où le constructeur private.

A priori, tu utilises un framework convertissant ta table en objet. regarde la documentation du framework ca doit être décrit dedans comment procéder

Vincent
3
Rejoignez-nous