its more complex then that,
because only specific donation are included in the filter string created by the forms textboxes.
[date range, amount, cause of donation]
What I did in the end is,
I added a Yes/No field CreateReceiptSelect to the Donations table
and divided the code in 2
the first part changes the CreateReceiptSelect field to true for all Donations in query filtered by the FilterString.
the 2nd part loops thru all records with CreateReceiptSelect field = true
and adds a receipt number according to the SetUp Type selected in Form.
the first part of code starts of by changing the CreateReceiptSelect field to false for all Donations.
Thank You every one
especially DBGuy
for the help & encouragement!!