Data Validation problem

placasse

Board Regular
Joined
Jun 14, 2010
Messages
90
Hi,
I am trying to do Data Validation on a cell in order to prevent the user to enter text data that has a lenght outside the range of 1 to 10 characters.

I use the Data Validation feature in Excel and select Input Lenght and put 1 as the minimum and 10 as the maximum and uncheck "Ignore blanks".

It does work OK except when I select the cell and hit the Delete key, the data validation doesn't trigger but the cell is empty meaning it has a count of 0 character.

Any idea why ?

Pierre
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
Excel always worked like this. You can delete the value even if the validation requests 1-10 digits. You just can't enter the cell, delete the contents and press enter.

I don't know a work around for this issue, except for vba.
 
Upvote 0
Hi,
thank you for the replies. I am not using VBA for the Data Validation.

If I Delete & Enter the cell, it doesn't validate either.

What will be an easy VBA to check this ? I supposed Worksheets Change Event...


Thank you
 
Upvote 0

Forum statistics

Threads
1,224,521
Messages
6,179,291
Members
452,902
Latest member
Knuddeluff

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top