Add new Rec's to a Sub frm when Allow Additions = False 
Author Message
 Add new Rec's to a Sub frm when Allow Additions = False

This is the scenario...
I have a form with a subform in it.
The Main form has the Allow Edits and Allow Additions set to False.

I enable these properties with a command button and then edit the record
and allow adding new records.

The problem is, is that when these options are enabled I can add/edit
records but can not add new records to the form in the SubForm window.

Any one know how to do it or get around it.

I have tried Requerying the Main form and the SubForm to no avail.

Regards

Steve Carson.



Wed, 18 Jun 1902 08:00:00 GMT  
 Add new Rec's to a Sub frm when Allow Additions = False

Forget this request...

I have worked around it by the following...

Main Form
AllowAdditions = True
AllowUpdates = True

Subform
AllowAdditions = True
AllowUpdates = True

On Open of Main Form
set the properties to False for both SubForm and Main Form.

When command button is pressed Set properties to True and requery the
form.

Thanks for reading.
Anyone got any other ways of doing this then I would appreciate their
suggestions.

Cheers

Steve.

Quote:
-----Original Message-----

This is the scenario...
I have a form with a subform in it.
The Main form has the Allow Edits and Allow Additions set to False.

I enable these properties with a command button and then edit the record
and allow adding new records.

The problem is, is that when these options are enabled I can add/edit
records but can not add new records to the form in the SubForm window.

Any one know how to do it or get around it.

I have tried Requerying the Main form and the SubForm to no avail.

Regards

Steve Carson.



Wed, 18 Jun 1902 08:00:00 GMT  
 Add new Rec's to a Sub frm when Allow Additions = False
Is your SubForm visible?

I had the problem that I had to set my Subform .visible = true
and .DataEntry = True in in a SubFormSetup function in the form_load
code (this was for a DataEntry app) of the main form.

Other wise with those SubForm's properties in design view it was still
invisible.



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Move to newrecord adds rec to db, but cant move to new rec

2. New Rec with Data Based on Previous Rec's Data

3. Can't add a new record on sub-sub-form

4. Can't show an UserForm (Frm.Show False does not work)

5. New record added to listbox, but won't load rec in form when selec

6. how do you allow additions in a sub form

7. sub Form does not allow additions

8. sub Form does not allow additions

9. Allow add records in frm

10. Editing Sub forms When Parent form Allow edits is set to false


 
Powered by phpBB® Forum Software © phpBB Group