allowadditions problem

bholiday

Registered User.
Local time
Today, 10:16
Joined
May 31, 2002
Messages
12
I have a command button that changes the allowadditions property from false to true so that I can add a record. Then I had it disable the allowadditions so that the subform wouldn't automatically add a new entry. However this does not seem to work because if I enter data in the form it automatically makes a new entry. If I put the allowadditions=false right after I allowadditions in the code it does not allow me to enter data. Is there somewhere to place the code so I can open the form and enter data without getting the new record.
Thanks
 
This has me a little confused. To enter data you can do one of two things - create new data or overwrite existing data
Do you have a main form / subform setup and if so, where do you want to allow / prohibit adding of new records, on the main form and/or on the subform?
 
sorry for confusion

Sorry for the confusion. I have a subform that shows what equipment a customer has. The main form shows the customer. I want to be able to add data to the subform when I press the new entry button in the footer section of the subform. However, i do not want the automatic new entry field to pop up as soon as I start entering data into the form. i hope this helps if you need any more info please ask.
 
I'm assuming that you are using a continuous subform with multiple rows of data. The method you are currently using is probably ok but I see your problem. I think that as soon as you start entering a new record, access automatically places a blank record below it and I don't think that there is any way around this despite your best efforts with the allow additions method. If you really do not want the blank record showing, I think the only way is for the add record button to open a separate form for data entry and on closing this, requerying the subform to display the updated data.
Sorry but that's the best I can do unless anyone has any solutions.
 
thanks

Thank you for your efforts. At least the validation that someone more experienced than myself thinks it is impossible boosts the ego a bit.
 

Users who are viewing this thread

Back
Top Bottom