Can you remove the green triangle using VBA?

rizzo93

Active Member
Joined
Jan 22, 2015
Messages
303
Office Version
  1. 365
My code pastes a formula into a column of cells that also contains a data validation list. This formula returns information if it can find it. If it can't, then the user can select a value from the list in the cell.

As a result, I get a green triangle telling me there is a data validation error. I understand why it's doing this, but I don't care as this doesn't negatively impact the purpose of the cell. I just want the error to be ignored.

I've read about turning the error-checking feature off in the settings, but I prefer handling this using VBA, if possible.

How can I get rid of this triangle using VBA in all the cells affected?
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
Maybe with

VBA Code:
Application.ErrorCheckingOptions.ListDataValidation = False
 
Upvote 0
Solution
That worked, JEC! Thanks!

What's odd is that ListDataValidation wasn't among the other choices for this issue on the Microsoft help site.

But the triangles on gone now. (y)
 
Upvote 0
Great! Below on the help page it actually exists

1691165830252.png
 
Upvote 0
That is a much different list compared to what I was referencing. It had half those values. But good to know. Thanks again.
 
Upvote 0

Forum statistics

Threads
1,223,228
Messages
6,170,871
Members
452,363
Latest member
merico17

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