close

I used this formula to seperate numbers in a string and return the
numbers.
Example:
original string quot;BD456quot;. the outcome is quot;456quot;

The formula worked just fine, but would someone please explain to me
how it did that. The functions used don't follow the standard format
that the stupid excel helper suggests; therefore, I didn't understand
them. The function for a string in cell G2 is

=MID(G2,MIN(SEARCH({0,1,2,3,4,5,6,7,8,9},G2amp;quot;01234 56789quot;)),1024)Thank you in advance.
Mahmoud--
nebrass
------------------------------------------------------------------------
nebrass's Profile: www.excelforum.com/member.php...oamp;userid=32802
View this thread: www.excelforum.com/showthread...hreadid=532211=MID(G2,MIN(SEARCH({0,1,2,3,4,5,6,7,8,9},G2amp;quot;01234 56789quot;)),1024)SEARCH({0,1,2,3,4,5,6,7,8,9},G2amp;quot;0123456789quot;)) will return an array of
{7,4,5,6,11,12,13,14,15,16} - note that these numbers relate to the position
in G2, but some are greater than 6 because we appended 0123456789

MIN will the return 4 - self explanatory

MID(A1, SEARCH(...),ROW(...),1024) then returns 1024 characters starting at
character 4, but as there are only 3 more, that is what you get, 123.

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

quot;nebrassquot; gt; wrote in
message ...
gt;
gt; I used this formula to seperate numbers in a string and return the
gt; numbers.
gt; Example:
gt; original string quot;BD456quot;. the outcome is quot;456quot;
gt;
gt; The formula worked just fine, but would someone please explain to me
gt; how it did that. The functions used don't follow the standard format
gt; that the stupid excel helper suggests; therefore, I didn't understand
gt; them. The function for a string in cell G2 is
gt;
gt; =MID(G2,MIN(SEARCH({0,1,2,3,4,5,6,7,8,9},G2amp;quot;01234 56789quot;)),1024)
gt;
gt;
gt; Thank you in advance.
gt; Mahmoud
gt;
gt;
gt; --
gt; nebrass
gt; ------------------------------------------------------------------------
gt; nebrass's Profile:
www.excelforum.com/member.php...oamp;userid=32802
gt; View this thread: www.excelforum.com/showthread...hreadid=532211
gt;
Note, if G2 holds ABX123XYZ, you will get 123XYZ.

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

quot;nebrassquot; gt; wrote in
message ...
gt;
gt; I used this formula to seperate numbers in a string and return the
gt; numbers.
gt; Example:
gt; original string quot;BD456quot;. the outcome is quot;456quot;
gt;
gt; The formula worked just fine, but would someone please explain to me
gt; how it did that. The functions used don't follow the standard format
gt; that the stupid excel helper suggests; therefore, I didn't understand
gt; them. The function for a string in cell G2 is
gt;
gt; =MID(G2,MIN(SEARCH({0,1,2,3,4,5,6,7,8,9},G2amp;quot;01234 56789quot;)),1024)
gt;
gt;
gt; Thank you in advance.
gt; Mahmoud
gt;
gt;
gt; --
gt; nebrass
gt; ------------------------------------------------------------------------
gt; nebrass's Profile:
www.excelforum.com/member.php...oamp;userid=32802
gt; View this thread: www.excelforum.com/showthread...hreadid=532211
gt;

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 software 的頭像
    software

    software

    software 發表在 痞客邦 留言(0) 人氣()