A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

save record



 
 
Thread Tools Display Modes
  #1  
Old September 24th, 2008, 07:33 AM posted to microsoft.public.access.tablesdbdesign
Alu_GK
external usenet poster
 
Posts: 51
Default save record

What is the difference between the command
docmd.save
and
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
both commands seem to save the record.
(access 2003, vista)
10x
--
Alu_GK
  #2  
Old September 24th, 2008, 08:53 AM posted to microsoft.public.access.tablesdbdesign
Maurice
external usenet poster
 
Posts: 1,585
Default save record

With the first option it is also possible to save other objects in the db for
instance forms. So when coding and making changes in designtime you can save
that in designtime as well. The second option is explicit for saving records.
--
Maurice Ausum


"Alu_GK" wrote:

What is the difference between the command
docmd.save
and
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
both commands seem to save the record.
(access 2003, vista)
10x
--
Alu_GK

  #3  
Old September 24th, 2008, 09:00 AM posted to microsoft.public.access.tablesdbdesign
Allen Browne
external usenet poster
 
Posts: 11,706
Default save record

DoCmd.Save saves any changes you have made to the form.

To save the record, turn off the form's Dirty property:
If Me.Dirty Then Me.Dirty = False
Provided the form has focus, this will work as well:
RunCommand acCmdSaveRecord.

The wizard code is ridiculous. What is actually asks for is to simulate
clicking the 5th item on the 6th menu of the standard forms menu that was
built into Access 95 (internally called version 7.) One day, somebody's
going to put that line into a book of nostalgic computer oddities. :-)

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Alu_GK" wrote in message
...
What is the difference between the command
docmd.save
and
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
both commands seem to save the record.
(access 2003, vista)
10x
--
Alu_GK


  #4  
Old September 24th, 2008, 09:01 AM posted to microsoft.public.access.tablesdbdesign
Alu_GK
external usenet poster
 
Posts: 51
Default save record

Thanks..
So if the user will change the font size or color in a text box, in the
"docmd.save" he will be able to save the change not only the data change.
And in the 2nd option the formating change won't be saved.
Is that correct ?

10x

--
Alu_GK


"Maurice" wrote:

With the first option it is also possible to save other objects in the db for
instance forms. So when coding and making changes in designtime you can save
that in designtime as well. The second option is explicit for saving records.
--
Maurice Ausum


"Alu_GK" wrote:

What is the difference between the command
docmd.save
and
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
both commands seem to save the record.
(access 2003, vista)
10x
--
Alu_GK

  #5  
Old September 24th, 2008, 09:38 AM posted to microsoft.public.access.tablesdbdesign
Alu_GK
external usenet poster
 
Posts: 51
Default save record

10x.
and i thought i was the only one who doesn't understand this usage of the
old command.
Thank u
--
Alu_GK


"Allen Browne" wrote:

DoCmd.Save saves any changes you have made to the form.

To save the record, turn off the form's Dirty property:
If Me.Dirty Then Me.Dirty = False
Provided the form has focus, this will work as well:
RunCommand acCmdSaveRecord.

The wizard code is ridiculous. What is actually asks for is to simulate
clicking the 5th item on the 6th menu of the standard forms menu that was
built into Access 95 (internally called version 7.) One day, somebody's
going to put that line into a book of nostalgic computer oddities. :-)

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Alu_GK" wrote in message
...
What is the difference between the command
docmd.save
and
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
both commands seem to save the record.
(access 2003, vista)
10x
--
Alu_GK



 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 05:33 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.