Forum Discussion

Adi96S's avatar
Adi96S
Copper Contributor
Oct 30, 2025

Drop-down list with data validation rule

Hello everyone, I need some help :)

I have two cells:

B5 –  amount, entered by users
K5 – a drop-down list with offer types

I want to create a data validation rule with an alert.
For example:
If K5 = "offer1", the amount in B5 should be between 200 and 1000.

So, if someone enters 2000, an alert message like “Wrong amount” should appear.

How can I set this up?

 

1 Reply

  • NikolinoDE's avatar
    NikolinoDE
    Platinum Contributor

    You can do this using Data Validation with a custom formula in Excel. Here’s a step-by-step guide:

     

    Select B5 (the cell where the amount is entered).

    Go to the menu: Data → Data Validation → Data Validation…

    In the Settings tab:

    • Allow: Custom
    • Formula: enter a formula that checks both the drop-down selection and the amount.

     

    Enter the formula

    Assuming your offer types are in K5, the formula is:

    =IF(K5="offer1", AND(B5>=200, B5<=1000), TRUE)

     

    Test it:

    Choose "offer1" in K5 and try entering 2000 in B5 → You should see your alert.

    Choose a different offer type → Any amount is allowed.

     

     

    My answers are voluntary and without guarantee!

     

    Hope this will help you.

Resources