I've tried everything and nothing works. I'm sure there's a very simple way to do this.
I have a form (Transactions - Deposits) with a subform (Transactions - Deposits Subform). In the subform I enter an amount paid (AmountSubform is the box name), and then select my Invoice Number from a drop down box (InvoiceNumber is box name). I have an Event Procedure afterupdate open a query (Transactons - Deposit Query). I then search for the InvoiceNumber I chose, and then go to the record column AmtPaid for this invoice.
Private Sub InvoiceNumber_AfterUpdate()
Dim searchrecord As Integer
Dim capitalamt As Currency
searchrecord = InvoiceNumber
capitalamt = AmtPaid
DoCmd.OpenQuery ("Transactions - Deposit Query")
DoCmd.FindRecord searchrecord, acAnywhere, True, acSearchAll
DoCmd.GoToControl "AmtPaid"
Now all I want to do is to copy the information from the subform box AmountSubform to the query column AmtPaid. Then close the query and close the main form and subform (I can do the closing part).
Any help much appreciated.
I have a form (Transactions - Deposits) with a subform (Transactions - Deposits Subform). In the subform I enter an amount paid (AmountSubform is the box name), and then select my Invoice Number from a drop down box (InvoiceNumber is box name). I have an Event Procedure afterupdate open a query (Transactons - Deposit Query). I then search for the InvoiceNumber I chose, and then go to the record column AmtPaid for this invoice.
Private Sub InvoiceNumber_AfterUpdate()
Dim searchrecord As Integer
Dim capitalamt As Currency
searchrecord = InvoiceNumber
capitalamt = AmtPaid
DoCmd.OpenQuery ("Transactions - Deposit Query")
DoCmd.FindRecord searchrecord, acAnywhere, True, acSearchAll
DoCmd.GoToControl "AmtPaid"
Now all I want to do is to copy the information from the subform box AmountSubform to the query column AmtPaid. Then close the query and close the main form and subform (I can do the closing part).
Any help much appreciated.