Forms Navigation

C

Clyde Ellingwood

I have a form with buttons to control record movement.
Go to next , Go to Previous, Add etc. I'm using the
standard button wizard, then I add some code.

My question is on Go To Next behaves like "Go To New"
after the last record. I prefer to have the user
use "Add". I've tried checking to see if the form text
box is Null, this does not work until the user clicks
Next again.

Does anyone have a method that works.

Thanks in Advance.

Clyde
 
C

Cheryl Fischer

Try the following code in the On Current event of your form:

Me.RecordsetClone.MoveLast
cmdPrevious.Enabled = Not Me.CurrentRecord = 1
cmdNext.Enabled = Not Me.CurrentRecord = Me.RecordsetClone.RecordCount


hth,
 
C

Clyde Ellingwood

-----Original Message-----
Try the following code in the On Current event of your form:

Me.RecordsetClone.MoveLast
cmdPrevious.Enabled = Not Me.CurrentRecord = 1
cmdNext.Enabled = Not Me.CurrentRecord = Me.RecordsetClone.RecordCount


hth,

--

Cheryl Fischer, MVP Microsoft Access
Law/Sys Associates, Houston, TX





.

Cherly,

Thanks! Worked great.

Clyde
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top