Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Save Main Form Record after action in subform

Status
Not open for further replies.

Drenda

Programmer
Sep 1, 2007
85
GB
Hello - can anyone help

I am trying to save a record in a form after an action in a subform and have entered
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
as an after update action on a subform datasheet control
It looks like this only saves the record on the subform but would like to save the main form record whilst still in the subform

Many thanks
 
Untested but I think you can do the following

if me.parent.dirty then me.parent.dirty = false
 
How are ya Drenda . . .
TheAceMan1 said:
When ever you move the focus from an edited record in the [blue]mainform[/blue] to a record in the subform . . . the main record is automatically saved![/blue]
In any and all circumstances (under current secnario presented by you) the mainforms record should be automatically saved! Unless the mainform is unbound!

So which is it?

The mainform is [blue]bound[/blue] or [blue]unbound[/blue]?

Calvin.gif
See Ya! . . . . . .

Be sure to see thread181-473997
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top