Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to update records displayed after delete-sw set by user

Status
Not open for further replies.

kronar30

Programmer
Sep 8, 2004
74
US
I use a subform based on a query to display records not yet deleted. One of the fields in the records is the delete-sw. How do I requery the records after user sets one of the records delete-sw (so that record no longer shows)?
 
How are ya kronar30 . . .

Do you want to atually delete the record or just not include it in the recordset? ... Is there some proprietary rule that takes precedence?

[blue]Your Thoughts? . . .[/blue]

See Ya! . . . . . .

Be sure to see faq219-2884 [blue]Worthy Reading![/blue] [thumbsup2]
Also faq181-2886 [blue]Worthy Reading![/blue] [thumbsup2]
 
Setting the delete-sw does delete the record in the table, but I dont know how to requery for the subform displayed.
 

How do you query it now?
Do you have delete-sw field in your query? Something like:
[tt]
SELECT * FROM MyTable
WHERE delete-sw <> 'Y'[/tt]

Have fun.

---- Andy
 
kronar30 said:
[blue] ... I dont know how to requery for the subform[/blue][/code]
If your code is running in the mainform:
Code:
[blue]   [subFormName].Form.Requery[/blue]
If your code is running in the subform:
Code:
[blue]   Me.Requery[/blue]


See Ya! . . . . . .

Be sure to see faq219-2884 [blue]Worthy Reading![/blue] [thumbsup2]
Also faq181-2886 [blue]Worthy Reading![/blue] [thumbsup2]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top