Extract sub string

S

sixbeforedawn

Hi

I need to extract the SMTP's from an Exchange export, I've been trin
to do it using MID but not having much luck :confused:

the string looks like this.

CCMAIL:secondname, firstname a
domainLON%MS:domain/domaon/alias%SMTP:[email protected]%X400:c=Country;a
;p=domain;o=domainLON;s=secondname;g=firstname;

and what I want to extract is (e-mail address removed)

can't seem to be able to start the extract at SMTP: and then end it a
%X400.

can anybody help?

TIA a newbie :
 
B

Bob Phillips

=MID(A1,FIND(":",A1,FIND("%SMTP:",A1)+1)+1,FIND("%",A1,FIND("%SMTP:",A1)+1)-
FIND(":",A1,FIND("%SMTP:",A1)+1)-1)

--

HTH

RP
(remove nothere from the email address if mailing direct)


"sixbeforedawn" <[email protected]>
wrote in message
news:[email protected]...
 
S

sixbeforedawn

sorted it ;)


=MID(A1, SEARCH("%smtp:",A1)+6, (SEARCH("%X400",A1)-6
SEARCH("%SMTP:",A1)))

Cheer
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top