Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Remove the first line form a Memo box 1

Status
Not open for further replies.

jmc014

Technical User
Nov 24, 2007
80
0
0
ES
I could do with a little help if some's got the time..

While I'm able to capture the frst line of text from my Memo Box, I would like to know if there is a way to capture the entire text form my memo box EXCEPT for the first line.

Here's the code that I use to capture the first lime of text:
MyCapture = Left([MyMemoBox], InStr(1, [MyMemoBox], vbCrLf) - 1)

Or... What's the best way to remove the first line from a memo box (which is what I'm trying to do)

Thanks for help.
JMC


 

MyCapture = Right([MyMemoBox], Len([MyMemoBox]) - InStr(1, [MyMemoBox], vbCrLf) + 1)


Skip,
[sub]
[glasses]Just traded in my OLD subtlety...
for a NUance![tongue][/sub]
 
Or:
[tt]
MyCapture = Mid([MyMemoBox], InStr(1, [MyMemoBox], vbCrLf) + 1)
[/tt]

Have fun.

---- Andy

A bus station is where a bus stops. A train station is where a train stops. On my desk, I have a work station.
 
@Andy, regarding your "stations:" Might stationary stationery be somewhat like write only memory?

Skip,
[sub]
[glasses]Just traded in my OLD subtlety...
for a NUance![tongue][/sub]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top