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  dBforums > PC based Database Applications > Microsoft Access > SelStart problem

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 11-13-10, 16:09
ybg1 ybg1 is offline
Registered User
 
Join Date: May 2007
Posts: 37
SelStart problem

Hi there,

I'm trying to open the form when the cursor sits at the end of the text
that previously was typed, after todays date was inserted on the next line.
It does all that but at first you see only the date, and to be able to see the
previous text you need to scroll with the top arrow otherwise it is invisable.

Private Sub Form_Current()
Me.Remarks.SetFocus
Me.Remarks = Me.Remarks & vbNewLine & Date
Me.Remarks.SelStart = Len(Me. Remarks)
End Sub

I've tried: Me.Remarks.SelStart = 0 and I can see the previous text but
of course the cursor sits in the begining of the page.

what I can do to have it sits after the inserted date and still see the previous text


thanks
Reply With Quote
  #2 (permalink)  
Old 11-13-10, 16:58
Sinndho Sinndho is online now
Registered User
 
Join Date: Mar 2009
Posts: 3,446
I don't understand your question but from what I can guess this seems normal to me: you're inserting a line break (vbNewLine) into the value of the textbox. If you then want to see it all, this textbox must be multiline (i.e. extends on more than one line).
__________________
Have a nice day!
Reply With Quote
  #3 (permalink)  
Old 11-14-10, 01:47
ybg1 ybg1 is offline
Registered User
 
Join Date: May 2007
Posts: 37
SelStart

Thank you for your help

I've solved the problem by using DoCmd.Maximize
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On