Go to end of notes text box

  • Thread starter Thread starter Eric Blitzer
  • Start date Start date
E

Eric Blitzer

Does anyone know the syntax that will automaticallly go to
the end of a "notes" text box? The command below works for
normal text boxes but goes to the 255th character of a
notes text box wich could be 64,000 characters.

me!Description.SelStart = me!Description.SelLength

Thanks
 
I don't know if SelStart will go beyond 255; however, you are setting the start position
to the length of selected text. What happens if you set it to the length of the text? Have
you tried a hard number, just for a test, to see if SelStart will move beyond 255?

Me!Description.SelStart = Len(Me!Description.Value)
 
wayne,

The reason I go to the start is this field is for case
notes and can contain quite a bit of data. It can even be
filled to 64,000 characters. Without any start position
the text box starts with all the text selected(highlighted)
and with a miss key can be erased. Starting at the
beginning or anywhere else deselets the text. I actually
use "selstart" rather than "Sellen". I feel it is better
to be at the beginning rather than 255 characters in to the
text. Too bad there is not a "selend"
Selstart - goes to the begginning
Sellen - goes to the end but not further than 255th character
Do you know syntax for going further than 255

Thanks
Eric
-----Original Message-----
I don't know if SelStart will go beyond 255; however, you are setting the start position
to the length of selected text. What happens if you set it
to the length of the text? Have
 
An alternative suggestion -

Set the Locked property of the text box to true and place a toggle button
beside it.

On the After Update event of the toggle button enter code like:

If Me.tglEditNotes Then
Select Case MsgBox ("Do you Intend to Edit the Cases Notes.", vbYesNo +
vbQuestion + vbDefaultButton2, "Unlock The Data...")
Case vbYes

Me.txtCaseNotes.Locked = False
Case vbNo

Me.txtCaseNotes.Locked = True
End Select
Else
Me.txtCaseNotes.Locked = True
End If

And on the forms Current Event enter code like:

Me.txtCaseNotes.Locked = True
Me.tglEditNotes = False

That would hopefully prevent the notes from being lost accidentally.
--

Cheers
Mark

Free Access/Office Add-Ins at:
http://mphillipson.users.btopenworld.com/
 
I will consider this. Thanks alot for your help. Have a
good weekend.

Eric
-----Original Message-----
An alternative suggestion -

Set the Locked property of the text box to true and place a toggle button
beside it.
 
Back
Top