Transferring BOOKING ID and Other booking details from one form to another

nish2009i

Registered User.
Local time
Today, 01:34
Joined
Jan 24, 2009
Messages
11
Hi This is very basic but i cant get my head round it since iv not used access in ages!

i have a booking form and a payment form. when the user clicks PAY button, i want the payment form opened with the Booking details they were viewing from the booking form. the Booking Id, cost and other details should come up in the payment form. PLEASE HELP!!!
 
If the payment form is only opened by the booking form then you can place pointers on your payments form to get information from the booking form

By using the OnLoad Event of the Payments forms you can code

Me.TxtBookingID = Forms("YourBookingFormName")("YourBookingIDControlName")

repeat for all the data you want to populate in the payments form. If the payments form can be opened from a different form then you may need to use the IsLoaded() function to test if the Bookings form is open.

David
 
hi, thanks a lot for that its working!!!
 
Also, while filling in the payment details, i would like to keep the COMPLETE TRANSACTION button inactive and i have put the code in for that and it doesnt work.. this is the code


Private Sub Form_current()
If cboPaid = "Yes" Then
cmdCompletePay.Enabled = True
Else
cmdCompletePay.Enabled = False
End If

End Sub




i hope this is the right one but still, when i select YES, in paid box, it doesnt make the button active. i dont konw why? thanks!
 
Also, while filling in the payment details, i would like to keep the COMPLETE TRANSACTION button inactive and i have put the code in for that and it doesnt work.. this is the code


Private Sub Form_current()
If cboPaid = "Yes" Then
cmdCompletePay.Enabled = True
Else
cmdCompletePay.Enabled = False
End If

End Sub




i hope this is the right one but still, when i select YES, in paid box, it doesnt make the button active. i dont konw why? thanks!
I would suggest you also put the code in the After Update event of the combo.

The point is the Current event only fires when you first load the record (or refresh it). Simply changing a value in the record won't fire the current event.

Chris
 

Users who are viewing this thread

Back
Top Bottom