Refreshing a table from a form

D

dave

I have a form connected to a table which has the ability to delete a record.
However when you delete a record it just replaces the data with #Deleted and
now i can select that in my combo box. is there a way to refresh the
table(through VB code or otherwise) so the #Deleted will stop showing up in
my combo box? Thanks.
 
O

Ofer

You don't refresh the table, you need to refresh the combo source

Use this to refresh the list, after you delete the record

Me.[ComboName].Requery
 
D

dave

I tried that and it didn't change anything thanks though.

Ofer said:
You don't refresh the table, you need to refresh the combo source

Use this to refresh the list, after you delete the record

Me.[ComboName].Requery

--
I hope that helped
Good Luck


dave said:
I have a form connected to a table which has the ability to delete a record.
However when you delete a record it just replaces the data with #Deleted and
now i can select that in my combo box. is there a way to refresh the
table(through VB code or otherwise) so the #Deleted will stop showing up in
my combo box? Thanks.
 
K

kabaka

You can try me.[ComboName].refresh, but if that doesn't work then I think
you'll have to hide the section it's in and then unhide it also. I'm pretty
sure that's what I ended up doing in the past.

me.section("Detail").visible = false
me.comboname.requery
me.section("Detail").visible = true

Try that. Good luck.

Ofer said:
You don't refresh the table, you need to refresh the combo source

Use this to refresh the list, after you delete the record

Me.[ComboName].Requery

--
I hope that helped
Good Luck


dave said:
I have a form connected to a table which has the ability to delete a record.
However when you delete a record it just replaces the data with #Deleted and
now i can select that in my combo box. is there a way to refresh the
table(through VB code or otherwise) so the #Deleted will stop showing up in
my combo box? Thanks.
 
Top