Seth Galitzer
sgsax at ksu.edu
Mon Feb 3 09:09:01 CST 2003
Terri, Ahhh, string-handling, one of my favorite topics. :) what you need to do is look at your data and find a consistent "flag" string, or a consistent pattern to the data. If the data you want is at the end of the string, and the text "CUT" always precedes it, then "CUT" is your flag. Use InStr() to find your flag text, and chop off anything after that. Like Roz mentioned, if the data you want is always the last six characters of the string, then you can use Right(). If it is always the last text following whitespace, you can start from the right side and look for the first whitespace. If you send more example lines from your source data, I can help you analyze it. Seth On Mon, 2003-02-03 at 08:22, Terri Jarus wrote: > I know this is very easy, but I can never remember exactly how to do this. I need to parse off some data from the end of a string. For example, the string: > > FLDR T TAB M CLIP#5 BLUE 11PT; 2 PLY STRAIGHT CUT 250/CS > > I want to parse out "250/CS". How do I set up the code to do this? This info is always going to be at the end of the string. > > Thanks for your help. If there is a website or information that I can put in my files as to how to work with strings, I could reference that in the future. -- Seth Galitzer sgsax at ksu.edu Computing Specialist http://puma.agron.ksu.edu/~sgsax Dept. of Plant Pathology Kansas State University