Validation Rule (Formula)

Hello Experts,

I have a worksheet, that I need to control if the user should be entering a value into a cell.

See image...

The weight columns, are the ONLY columns the user is allowed to type but ONLY IF there is a pallet # to the left.

Is it possible to reject a weight, if there's no pallet listed?

Thank you in advance for your help!

~ Geekamo
Who is Participating?
Patrick MatthewsConnect With a Mentor Commented:
It looks like your data start in Row 5 or so.  So...

1) Select F5:F?????

2) Go to Data Validation, type Custom, using formula:


That will only allow entries in Col F if both Col E and Col F have numeric values.
FlysterConnect With a Mentor Commented:
Click on cell F1. Go to the data tab - data validation. Under the Settings tab go to Allow and select Custom. In Formula enter "=LEN(E1)>0" (without quotes.) Make sure Ignore Blank is unchecked. Copy F1, highlight F2 to whatever ending cell you want. Right-click one of the cells, select paste special - validation. That should work for you.

GeekamoAuthor Commented:
@ matthewspatrick,

I ended up using, "=COUNT($E3)=1".

@ Flyster,

I wasn't familiar with the LEN function, but that's pretty cool how that function gets the same answer in a different way. (I just read up on it to see how it functions)

@ All,

For now, I'll stick with the COUNT function - only because I am more familiar with it. But you both gave me great answers.

Any objections to me splitting the points between you both?

~ Geekamo
Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.


LEN function gives you the LENGTH of the data in the cell. So if your name was in A1, LEN(A1) would give you 7.  I have no problem with you giving Matthewspatrick all the points. His response was first and chosen. I'm just glad you found a solution to your problem.
Patrick MatthewsCommented:
Either way suits me :)
GeekamoAuthor Commented:
@ all,

400/100 split

Thank you again!

~ Geekamo
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.