technocraze
01-15-2007, 09:03 AM
Private Sub ListBox1_AfterUpdate event()
Dim rs as Object
Set rs = RecordSet.Clone
rs.FindFirst "[Serialno] = " & Str(Nz(Me![ListBox1]))
if not rs.EOF then Me.Bookmark = rs.Bookmark
Me.Text1.Value = ListBox1.Column(0) (suspect this line is the main error)
Elaboration
Serial no = pk
Listbox1 = populated list
I am using MS Acess and visual basic, what i want to achieve is to display the selected value from the listbox and put in the textbox. But dnt get it why i always get this annoying error! Very much appreciated if u guys can assist me in pointing or highlighting out the error. Tks for any kind advice and assistance in advance.
Error: CancelUpdate or Update without AddNew or Edit.
Tks.
Dim rs as Object
Set rs = RecordSet.Clone
rs.FindFirst "[Serialno] = " & Str(Nz(Me![ListBox1]))
if not rs.EOF then Me.Bookmark = rs.Bookmark
Me.Text1.Value = ListBox1.Column(0) (suspect this line is the main error)
Elaboration
Serial no = pk
Listbox1 = populated list
I am using MS Acess and visual basic, what i want to achieve is to display the selected value from the listbox and put in the textbox. But dnt get it why i always get this annoying error! Very much appreciated if u guys can assist me in pointing or highlighting out the error. Tks for any kind advice and assistance in advance.
Error: CancelUpdate or Update without AddNew or Edit.
Tks.