Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 52
Default seperate the character and number in formula



A1 : dfg56Yt - B1 : dfgYt - C1 : 56
A2 : 549pp - B2 : pp - C2 : 549

I want to make above.
using only excel embedded function, not UDF.
namely in column B, only character
namely in column C, only number

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default seperate the character and number in formula

Hi,

Enter a formula in B1:

=SUBSTITUTE(A1,C1,)

Enter a formula in C1:

=MID(A1,MIN(IF(ISERROR(FIND({1,2,3,4,5,6,7,8,9,0}, A1)),"",
FIND({1,2,3,4,5,6,7,8,9,0},A1))),MAX(IF(ISERROR(FI ND(
{1,2,3,4,5,6,7,8,9,0},A1)),"",FIND({1,2,3,4,5,6,7, 8,9,0},
A1)))-MIN(IF(ISERROR(FIND({1,2,3,4,5,6,7,8,9,0},A1)),"",
FIND({1,2,3,4,5,6,7,8,9,0},A1)))+1)

Then drag and fill down.


--
Regards,
Soo Cheon Jheong
_ _
^¿^
--



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 691
Default seperate the character and number in formula

Doesn't work for aa11bb22 but then there wasn't
a proper definition of the data to be used. If there is
only one contiguous area of digits then it works fine.

In any case the poster wanted digits in one cell and
letters in another cell, and there were two sets of
letters in the example.

When things get complicated I don't have the patience
to code a worksheet function instead of a user defined function.
Some UDFs using Regular Expressions which can be adapted
can be found in
Extraction of a Group of Digits and Dashes
http://www.mvps.org/dmcritchie/excel/grove_digitsid.htm
from postings by Harlan Grove
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Soo Cheon Jheong" <exceler@korea wrote in message ...
Hi,

Enter a formula in B1:

=SUBSTITUTE(A1,C1,)

Enter a formula in C1:

=MID(A1,MIN(IF(ISERROR(FIND({1,2,3,4,5,6,7,8,9,0}, A1)),"",
FIND({1,2,3,4,5,6,7,8,9,0},A1))),MAX(IF(ISERROR(FI ND(
{1,2,3,4,5,6,7,8,9,0},A1)),"",FIND({1,2,3,4,5,6,7, 8,9,0},
A1)))-MIN(IF(ISERROR(FIND({1,2,3,4,5,6,7,8,9,0},A1)),"",
FIND({1,2,3,4,5,6,7,8,9,0},A1)))+1)

Then drag and fill down.


--
Regards,
Soo Cheon Jheong
_ _
^¿^
--





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
Seperate text and number to different cells Seperate text and number Excel Discussion (Misc queries) 3 May 21st 10 02:02 PM
seperate street name and number Bobby Excel Worksheet Functions 2 April 19th 07 06:20 PM
How do I seperate a 10 digit number into one cell for each number? Tkriger Excel Discussion (Misc queries) 2 January 26th 07 04:29 PM
remove cr character from a + number and change number to - 159cr Cr character on numbers Excel Worksheet Functions 3 March 10th 06 10:34 PM
seperate number and character in a cell a rohi Excel Programming 1 November 27th 04 10:43 AM


All times are GMT +1. The time now is 11:19 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"