Predmet:User control
Pravam edna user controla koja treba da e identicna so textbox no ne znam kao treba da se vnesat parametri za DataSource i DataField.
jas kaj mene staviv
PreuzmiIzvorni kôd (Visual Basic):Public Property Get DataSource() As String
DataSource = txtNum.DataSource
End Property
Public Property Let DataSource(ByVal New_DataSource As String)
txtNum.DataSource = New_DataSource
PropertyChanged "DataSource"
End Property
'Fild
Public Property Get DataField() As String
DataField = txtNum.DataField
End Property
Public Property Let DataField(ByVal New_DataField As String)
txtNum.DataField = New_DataField
PropertyChanged "DataField"
End Property
Private Sub UserControl_WriteProperties(PropBag As PropertyBag)
PropBag.WriteProperty "DataSource", txtNum.DataSource, ""
PropBag.WriteProperty "DataField", txtNum.DataField, ""
End Sub
Private Sub UserControl_ReadProperties(PropBag As PropertyBag)
txtNum.DataSource = PropBag.ReadProperty("DataSource", "")
txtNum.DataField = PropBag.ReadProperty("DataField", "")
End Sub
koga ke ja stavam kontrolata na forma dobivam poraka Metod od data member not faund i obelezano e
.DataSource=