Thread: small function
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bernie Deitrick Bernie Deitrick is offline
external usenet poster
 
Posts: 5,441
Default small function

ATishoo,

I would use a column of helper formulas: extract the leading numbers using this array formula in J18

=LEFT(I18,MIN(IF(CODE(MID(I18,ROW(INDIRECT("A1:A"& LEN(I18))),1))57,ROW(INDIRECT("A1:A"&LEN(I18)))))-1)*1

copied to J30, then use this array formula to get the minimum:

=MIN(IF(ISERROR(J18:J30),"",J18:J30))

HTH,
Bernie
MS Excel MVP


"Atishoo" wrote in message
...
=SMALL(--LEFT(I18:I30,3),1)

how do I get this function to ignore empty cells in the range I18:I30 and to
still work when some of the numbers are less than 3 numbers in length (there
is text as well in some cells thats why I have limited it to 3 numbers.)