Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default Extracting text before ~ sign

Hi Everyone,


Please help me with your expertise. I have this type of data
(12345~Sample), that series is a code followed by the code name. Now I
want to get only the code after the ~ sign, my problem is the code is
not fix, some codes consist of 3 characters only so I cannot just use
the simple left(A1,#) formula.


Thanks in advance!


Jerome
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,501
Default Extracting text before ~ sign

Maybe

=MID(A1,FIND("~",A1)+1,LEN(A1))

Mike

"jhong" wrote:

Hi Everyone,


Please help me with your expertise. I have this type of data
(12345~Sample), that series is a code followed by the code name. Now I
want to get only the code after the ~ sign, my problem is the code is
not fix, some codes consist of 3 characters only so I cannot just use
the simple left(A1,#) formula.


Thanks in advance!


Jerome

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,501
Default Extracting text before ~ sign

Sorry you wanted the text before the tilde

=LEFT(A1,FIND("~",A1)-1

Mike

"jhong" wrote:

Hi Everyone,


Please help me with your expertise. I have this type of data
(12345~Sample), that series is a code followed by the code name. Now I
want to get only the code after the ~ sign, my problem is the code is
not fix, some codes consist of 3 characters only so I cannot just use
the simple left(A1,#) formula.


Thanks in advance!


Jerome

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Extracting text before ~ sign

Your subject says you want the text before the sign and your message says
the text after the sign; so, here is both...

Befo =LEFT(A1,FIND("~",A1&"~")-1)

After: =MID(A1,FIND("~",A1&"~")+1,999)

Rick


"jhong" wrote in message
...
Hi Everyone,


Please help me with your expertise. I have this type of data
(12345~Sample), that series is a code followed by the code name. Now I
want to get only the code after the ~ sign, my problem is the code is
not fix, some codes consist of 3 characters only so I cannot just use
the simple left(A1,#) formula.


Thanks in advance!


Jerome


  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default Extracting text before ~ sign

Thanks Mike for the reply. I've tried your formula and I am getting
the account name's from my data, is there a way to change this formula
so I can get the code only from my file? Many thanks in advance!!

On Mar 5, 4:26*pm, Mike H wrote:
Maybe

=MID(A1,FIND("~",A1)+1,LEN(A1))

Mike



"jhong" wrote:
Hi Everyone,


Please help me with your expertise. I have this type of data
(12345~Sample), that series is a code followed by the code name. Now I
want to get only the code after the ~ sign, my problem is the code is
not fix, some codes consist of 3 characters only so I cannot just use
the simple left(A1,#) formula.


Thanks in advance!


Jerome- Hide quoted text -


- Show quoted text -




  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default Extracting text before ~ sign

Thanks Mike! You save my day!!!


On Mar 5, 4:30*pm, Mike H wrote:
Sorry you wanted the text before the tilde

=LEFT(A1,FIND("~",A1)-1

Mike



"jhong" wrote:
Hi Everyone,


Please help me with your expertise. I have this type of data
(12345~Sample), that series is a code followed by the code name. Now I
want to get only the code after the ~ sign, my problem is the code is
not fix, some codes consist of 3 characters only so I cannot just use
the simple left(A1,#) formula.


Thanks in advance!


Jerome- Hide quoted text -


- Show quoted text -


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I get a text to contain a quotation sign? jkrons Excel Discussion (Misc queries) 3 October 20th 09 06:59 PM
how do I copy text with a plus sign at the front? rich Excel Discussion (Misc queries) 2 March 2nd 09 06:17 PM
how to use the + sign in text David Excel Discussion (Misc queries) 2 June 4th 08 11:58 AM
Equal Sign As Text Trussy Excel Discussion (Misc queries) 1 January 5th 06 11:56 PM
extracting text from within a cell - 'text to rows@ equivalent of 'text to columns' Dan E[_2_] Excel Programming 4 July 30th 03 06:43 PM


All times are GMT +1. The time now is 08:41 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"