1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
|
Class MonObjet
Private _LaValeurExacte As Decimal
Public ReadOnly Property LaValeurExacte As Decimal
Get
Return _LaValeurExacte
End Get
End Property
End Class
Class Form1
Sub New()
InitializeComponent()
Dim b As New Binding("Text", instanceDeMonObjet, "LaValeurExacte")
AddHandler b.Format, AddressOf ValeurExacteVersTexteAffichage
AddHandler b.Parse, AddressOf TexteAffichageVersValeurExacte
End Sub
Private Sub ValeurExacteVersTexteAffichage
(sender As Object, e As ConvertEventArgs)
'...
End Sub
Private Sub TexteAffichageVersValeurExacte
(sender As Object, e As ConvertEventArgs)
'...
End Sub
End Class |