Results 1 to 4 of 4
  1. #1
    DaveShmave
    Guest

    LTrim Help Needed.

    Hi All,

    I want to trim all in a text field except the last letter / value. So if I trimmed 'DaveShmaveX' (without the quotes), I'd only be left with X. I've looked at the online help and have messed around with this for a while with no success.

    Can someone clue me into how you'd trim all but the last letter / value?

    TIA

    Dave <img src=/S/smash.gif border=0 alt=smash width=30 height=26>

  2. #2
    3 Star Lounger
    Join Date
    Dec 2000
    Location
    Manassas, Virginia, USA
    Posts
    363
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: LTrim Help Needed.

    You can get the result you need with Right(FieldName,1)
    Judy Jones, Computer Training Specialist
    Manassas, Virginia

  3. #3
    3 Star Lounger
    Join Date
    Mar 2001
    Location
    Minneapolis, Minnesota, USA
    Posts
    262
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: LTrim Help Needed.

    A quick caveat here: if you have any trailing spaces in your names, a la <pre>"DaveSchmaveX "</pre>

    , taking the right-most 1 characters will get you the space. You may want to use the Right() function in conjunction with the Trim() function which will trim off all preceding and trailing spaces:

    Right(Trim([FieldName]),1)
    <font face="Comic Sans MS"><font color=blue>~Shane</font color=blue></font face=comic>

  4. #4
    DaveShmave
    Guest

    Re: LTrim Help Needed.

    Thank you both, Shane and Judy! It's much appreciated.

    Dave

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •