Welcome, Guest. Please Login
Tinderbox
  News:
IMPORTANT MESSAGE! This forum has now been replaced by a new forum at http://forum.eastgate.com and no further posting or member registration is allowed. The forum is still accessible via read-only access for reference purposes. If you wish to discuss content here, please use the new forum. N.B. - posting in the new forum requires a fresh registration in the new forum (sorry - member data can't be ported).
  HomeHelpSearchLogin  
 
Pages: 1
Send Topic Print
removing text from a note but keeping some text (Read 3273 times)
Sebastian Stephenson
Full Member
*
Offline



Posts: 100

removing text from a note but keeping some text
Mar 17th, 2009, 5:45pm
 
I use the email to tinderbox feature and I use an iphone and I have  a signature on the iphone and I want to remove this string form the texts notes but with keeping other text in the notes text as well how can I do this with an agent?

thanks
Back to top
 
 
Sebastian Stephenson sebey9   IP Logged
Mark Bernstein
YaBB Administrator
*
Offline

designer of
Tinderbox

Posts: 2871
Eastgate Systems, Inc.
Re: removing text from a note but keeping some text
Reply #1 - Mar 17th, 2009, 6:46pm
 
This will require some moderately advanced work with regular expressions.

General approach: match the signature with one subexpression and the rest of the note with another:

     (.+)(...signature pattern...)

Now, the rest of the note is $1 and the signature $2, so

    $Text=$1

should do the trick.
Back to top
 
 
WWW   IP Logged
Pages: 1
Send Topic Print