Checking Column Constraints

  • Thread starter Thread starter SHAWTY721
  • Start date Start date
S

SHAWTY721

I am trying to figure out a way to check to see if the cells in a column have
6 characters and if it doesn't is there a way I can have zeroes inserted for
the cells that don't contain 6 characters in the designated column.
 
=if(len(cellref)=6,len(cellref),0)

By the above, if the length of word/number in the cell is '6' it would
return the length which itself is '6' and if its not it would return '0'.
cellref is cell reference example 'a1'.
 
Hi,

Cell Format as "000000"
Or in another column : =LEFT("000000"; 6-LEN(A1) ) & A1
Or =IF(LEN(A3)=6;"";
LEFT("000000"; 6-LEN(A3) ) & A3)
Regards
JY
 

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

Back
Top