Command Button

J

jbrickey

I would like to create a command button that would open a new record and keep
the meeting number from the current record and then give the next sequential
number to the meeting item.

Any help would be greatly appreciated.

Jana
 
O

Ofer

In the onclick event of the button write the code

Dim meetingnumber as Double, meetingitem as Number

meetingnumber = Me.[meeting number Field Name]
meetingitem = Me.[meeting item Field Name]

DoCmd.GoToRecord , , acNewRec

Me.[meeting number Field Name] = meetingnumber
Me.[meeting item Field Name] = meetingitem + 1
 
J

jbrickey

Thank you very much. That worked great.

Ofer said:
In the onclick event of the button write the code

Dim meetingnumber as Double, meetingitem as Number

meetingnumber = Me.[meeting number Field Name]
meetingitem = Me.[meeting item Field Name]

DoCmd.GoToRecord , , acNewRec

Me.[meeting number Field Name] = meetingnumber
Me.[meeting item Field Name] = meetingitem + 1


--
In God We Trust - Everything Else We Test


I would like to create a command button that would open a new record and keep
the meeting number from the current record and then give the next sequential
number to the meeting item.

Any help would be greatly appreciated.

Jana
 
Top