truncate

C

cathal

how can I limit the contents of a cell to 100 words? In other words, i
a cell contains 105 can I have a cut-off at 100?

thanks - catha
 
G

Govind

Hi,

If your data is in A1, you can enter add a helper column B,and enter
thsi formula in B1.

=LEFT(A1,MIN(100,A1))

This will trucate the values in column A to 100.

Regards

Govind.
 
J

JE McGimpsey

One way, sort of...

You can limit the number of spaces. Data/Validation:

Allow: Custom
Formula: =LEN(A1)-LEN(SUBSTITUTE(A1," ","")) < 100

You could ignore double spaces:

Allow: Custom
Formula: =LEN(SUBSTITUTE(A1," "," "))-LEN(SUBSTITUTE(SUBSTITUTE(A1,
" "," ")," ","")) < 100

but that wouldn't catch triple-spaces.

Neither would catch words separated by hyphens or n-dashes, ellipses,
etc.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top