ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Locking Cell through Validation (https://www.excelbanter.com/excel-worksheet-functions/195095-locking-cell-through-validation.html)

Premanand Sethuraman

Locking Cell through Validation
 
Dear All,
I am working in a program in which I want to lock a Cell in such a way like
if A1 = "Boiler" , then Cell A2 should not allow the user to enter the
number more than 28,800. If A1 = Any text other than boiler then Cell A2 can
alow the user to enter the number more than 28,800 but should not be more
than 68,000.
Please guide me how I can I do this with Data Validation. I tried with Data
Validation--- Allow--- Custom, but in vain.

Thanks and Regards,
Premanand.S


Max

Locking Cell through Validation
 
Select A2, then try this as the formula in DVAllowCustom:
=OR(AND(A1="Boiler",A2<=28800,ISNUMBER(A2)),AND(A1 <"Boiler",A2<=68800,ISNUMBER(A2)))
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:15,900 Files:354 Subscribers:53
xdemechanik
---
"Premanand Sethuraman" wrote:
Dear All,
I am working in a program in which I want to lock a Cell in such a way like
if A1 = "Boiler" , then Cell A2 should not allow the user to enter the
number more than 28,800. If A1 = Any text other than boiler then Cell A2 can
alow the user to enter the number more than 28,800 but should not be more
than 68,000.
Please guide me how I can I do this with Data Validation. I tried with Data
Validation--- Allow--- Custom, but in vain.

Thanks and Regards,
Premanand.S


Premanand Sethuraman

Locking Cell through Validation
 
Thanks Max, for providing the clear solution for my query
Prem.

"Max" wrote:

Select A2, then try this as the formula in DVAllowCustom:
=OR(AND(A1="Boiler",A2<=28800,ISNUMBER(A2)),AND(A1 <"Boiler",A2<=68800,ISNUMBER(A2)))
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:15,900 Files:354 Subscribers:53
xdemechanik
---
"Premanand Sethuraman" wrote:
Dear All,
I am working in a program in which I want to lock a Cell in such a way like
if A1 = "Boiler" , then Cell A2 should not allow the user to enter the
number more than 28,800. If A1 = Any text other than boiler then Cell A2 can
alow the user to enter the number more than 28,800 but should not be more
than 68,000.
Please guide me how I can I do this with Data Validation. I tried with Data
Validation--- Allow--- Custom, but in vain.

Thanks and Regards,
Premanand.S


Max

Locking Cell through Validation
 
Welcome, Prem
--
Max
Singapore
http://savefile.com/projects/236895
Downloads:16,000 Files:354 Subscribers:53
xdemechanik
---
"Premanand Sethuraman" wrote
in message ...
Thanks Max, for providing the clear solution for my query
Prem.





All times are GMT +1. The time now is 11:20 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com