![]() |
|
|
|
#1
|
||||
|
||||
|
You can do this with a forumula: =(LEN(B2)-LEN(SUBSTITUTE(B2,"1w","")))*1+(LEN(B2)-LEN(SUBSTITUTE(B2,"2w","")))*2+(LEN(B2)-LEN(SUBSTITUTE(B2,"3w","")))*3+(LEN(B2)-LEN(SUBSTITUTE(B2,"4w","")))*4+(LEN(B2)-LEN(SUBSTITUTE(B2,"5w","")))*5+(LEN(B2)-LEN(SUBSTITUTE(B2,"6w","")))*6+(LEN(B2)-LEN(SUBSTITUTE(B2,"7w","")))*7+(LEN(B2)-LEN(SUBSTITUTE(B2,"8w","")))*8 where the data are in B2. The above formula caters for up to 8w - you can add more expressions if you need. Note that I haven't bothered adding the 'w' to the formula results. You could do that with a custom number format (0w).
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
|
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
How to write the degree, minute second format in excel
|
Jamal NUMAN | Excel | 12 | 07-09-2018 11:44 PM |
| Is it possible to write down a number starting with zero in excel cell? | Rahmat_uk20 | Excel | 3 | 06-08-2012 02:26 AM |
Read text Report file with VBA and write parsed fields to Excel workbook
|
tpcervelo | Excel Programming | 1 | 01-05-2012 10:14 PM |
Word Count in Excel
|
dallas | Excel | 1 | 11-23-2011 09:20 AM |
Count in Excel
|
zanat0s | Excel | 3 | 06-09-2011 10:53 AM |