Solved

trim ( off string

Posted on 2007-03-19
4
809 Views
Last Modified: 2008-01-09
Hello Experts,
Can you help me with string manipulation?
I would like to take this string:
English Language(2)
and take of the everything to the right of the parenthesis so the string looks like this:
English Language
I have made a few attemps with no luck.
Any help you can provide would be appreciated.
0
Comment
Question by:shogun5
  • 2
  • 2
4 Comments
 
LVL 100

Accepted Solution

by:
mlmcc earned 50 total points
Comment Utility
Try this

Create a frmula
Name - RemoveParen
Formula
Local NumberVar ParenLoc;
ParenLoc := InStr({YourString}, "(");
Left({YourString},ParenLoc-1)

mlmcc
0
 

Author Comment

by:shogun5
Comment Utility
Yep...that was it!  
Thank you.
Can you explain what is happening with this code:

  Left({YourString},ParenLoc-1)

Thank you.
0
 
LVL 100

Expert Comment

by:mlmcc
Comment Utility
Left(String,Length)

It takes the first length characters of the string.
ParenLoc has the position of the ( so you want the characters upto but not including that one thus the need to subtract 1

mlmcc
0
 

Author Comment

by:shogun5
Comment Utility
Thank you.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
This video discusses moving either the default database or any database to a new volume.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now