[VB]Pb update entre mon group textbox(i) et ma DataSource
salut,
suite à mon message précédent, voici mon code (qui fonctionne !! :D) :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
|
Dim bnd As BindingCollection
Set cn = New ADODB.Connection
Set rs = New ADODB.Recordset
Set bnd = New BindingCollection
Dim MonSQL As String
MonSQL = "SELECT * FROM donnees where donnees.id=13328"
cn.Provider = "MSDataShape"
cn.Open ChaineADO
rs.CursorLocation = adUseClient
rs.Open MonSQL, cn, adOpenDynamic, adLockOptimistic, adCmdText
rs.MoveFirst
If rs.EOF <> True Or rs.BOF <> True Then
Set bnd.DataSource = rs
With bnd
.Add MyText(0), "Text", "Nom", , "Nom"
.Add MyText(1), "Text", "Prenom", , "Prenom"
.Add MyText(2), "Text", "Adresse", , "Adresse"
...
End With
End If |
mon enregistrement s'affiche parfaitement mais lorsque je modifie la valeur d'un champ sur mon textbox, la maj de ma datasource ne s'effectue pas.
je dois donc passer à côté d'une propriété de type allowupdate sur mon textbox ? non ?