ravgarwa1:
Post that other 3 fields are ...
No idea what this is supposed to mean. I'm guessing you didn't read your post before submitting it again. It will be very hard to help you if you don't put the basic effort in. I can only guess what you mean, and as it seems you're quite inexperienced that's even harder. I can see what makes sense but I can't follow the logic if there is none.
That's fine. We all have to start somewhere. There's nothing wrong with being inexperienced - it just means that your explanation is more important. Without it making sense it's very hard to advise you how to handle your problem.
My guess is that you have three unbound Controls on your Form (Date, Attendance & Leave Type) that you want to save somewhere. If so then you need to include the Fields from the table where they should be saved in the
RecordSource
of either your main Form or one of the Subforms. IE. They must be bound Controls.
I can help with one tip that is certainly relevant from looking at your code - Setting the
RecordSource
property runs the query immediately. There's no requirement to run
.Requery()
. It often does very little harm but for slow queries it can increase the response time for the user. It basically runs the same query twice so it makes sense it will take longer.