N
Nicolas
Yes another question about databindings.
All my controls are have databindings and works fine for navigating, adding,
deleting etc.
What I want is when I create a New record have those fields pre-fill with
some value stored in my user.setting so the user doesn't have to re-type
evrything all the time.
Should be so straight forward that I don't get it! The fields are not
getting populated with those values.
What is wrong with this code or method that I'm using?
Private Sub TenantsBindingSource_AddingNew(ByVal sender As Object, ByVal e
As System.ComponentModel.AddingNewEventArgs) Handles
TenantsBindingSource.AddingNew
Me.txt_Address.Text = My.Settings.Address
Me.txt_BasicPrice.Value = My.Settings.BasicPrice
Me.txt_City.Text = My.Settings.City
Me.txt_Country.Text = My.Settings.Country
Me.txt_PostalCode.Value = My.Settings.PostalCode
Me.txt_Province.Text = My.Settings.Province
Me.txt_Suite.Text = My.Settings.Suite
End Sub
Thanks for the help
All my controls are have databindings and works fine for navigating, adding,
deleting etc.
What I want is when I create a New record have those fields pre-fill with
some value stored in my user.setting so the user doesn't have to re-type
evrything all the time.
Should be so straight forward that I don't get it! The fields are not
getting populated with those values.
What is wrong with this code or method that I'm using?
Private Sub TenantsBindingSource_AddingNew(ByVal sender As Object, ByVal e
As System.ComponentModel.AddingNewEventArgs) Handles
TenantsBindingSource.AddingNew
Me.txt_Address.Text = My.Settings.Address
Me.txt_BasicPrice.Value = My.Settings.BasicPrice
Me.txt_City.Text = My.Settings.City
Me.txt_Country.Text = My.Settings.Country
Me.txt_PostalCode.Value = My.Settings.PostalCode
Me.txt_Province.Text = My.Settings.Province
Me.txt_Suite.Text = My.Settings.Suite
End Sub
Thanks for the help