IF Formula Based on CELL COLOUR Using VBA Function

  Рет қаралды 24,624

Chester Tugwell

Chester Tugwell

4 жыл бұрын

This video demonstrates how to write a VBA function that will return TRUE if a specified background colour has been applied to a cell. The VBA function can be used as the logical test in an IF statement. If you would prefer a non-VBA solution please see • IF Statement in Excel ...
The video will be useful if you are asking the following questions:
Can you do an IF statement in Excel based on color?
IF cell colour is red, then....
------------------------

Пікірлер: 15
@rpross1986
@rpross1986 2 жыл бұрын
Bravo!! VBA Excel Sheets for the win! Ty for the simple code examples
@emilyandnugget2058
@emilyandnugget2058 2 жыл бұрын
Hi this was a very helpful tip, however it doesn't seem to work with conditional formatting. Have you every noticed this and found a solution?
@antonisapergis1260
@antonisapergis1260 3 жыл бұрын
Mr. Tugwell your video is very helpful. I only have one problem. After setting the calculation command on the vba, I cannot copy and paste in the sheet. Is there a solution? Thank you in advance.
@lyndseychristman9071
@lyndseychristman9071 2 жыл бұрын
Mr. Tugwell, thank you so much for the video! I do have an issue I am running into though and am hoping you can help. I created the calculate code for my worksheet and it updates my calcs once the color changes, however, when I close out of the spreadsheet and go back in, any changes I make to the colors are not automatically updating. I have to go back into VBA and essentially refresh the code for it to start automatically re-calculating again. Any ideas?
@EdMarbach
@EdMarbach 2 күн бұрын
Just starting to learn VBA. Your example is close to my needs, but instead I'm trying to search for specific text in a cell and change color and strikethrough for just that portion of text. For this string "N1229A, N1499A, N1709A" I need to change only N1499A to blue and strikethrough. Can you help?
@vasileios_giannakidis
@vasileios_giannakidis 2 жыл бұрын
Hey Chester. What a helpful video. However, if you could help me please as I am going to break my mind. I want to know how I can write commands to clear contents from specific cells for example a1 to a7 if a8 says No. Please help!!!!
@SynfinityMSP
@SynfinityMSP 2 жыл бұрын
Awesome vid
@ankurbajaj84
@ankurbajaj84 3 жыл бұрын
Sir , video is helpful but when I am using the same function wherein if two cells are same color if statement runs .. it works however when I undo color to white or change colour which is not true, Then it does not update the false condition. Pls cna you help
@marinacicchi3272
@marinacicchi3272 9 ай бұрын
Hi Chester - Is it possible to do something similar but instead of using it as a formula, to format a current file? I have an excel file that was created with cells in different colours (instead of text) - but it was done manually through time so no conditional formatting applied. For example an orange cell means X a green cell means Y - now what i am trying to do getting the cell to say X or Y based on the colour - is that possible? to analyse the full excel worksheet and change the colours for text? Thank you
@omarkouatli828
@omarkouatli828 11 ай бұрын
what if conditional formatting is changing my cell color? It doesnt work anymore
@Joda-es5xd
@Joda-es5xd 4 жыл бұрын
Afternoon Sir, I created a VBA that when executed, would use ifs statements and copy and paste from the master data tab to the specific tabs in the same workbook. In other words, the Master Data is the entry form and then the VBA does the sorting and copying of the entire row Data and copies it to the specific tabs. My workbook has a total of 5 tabs, the issue I have is, every time the VBA is run, it duplicates the same data and any new data that was added. Do you think maybe you have a code or video that can be used to illustrate, so it does not duplicate the data or correct this issue, please advise?
@ChesterTugwell
@ChesterTugwell 4 жыл бұрын
I am afraid I don't have a video that deals with that. You are obviously copying all records rather than just the new one. Assuming that the new records is the last row you enter in your data sheet, you will be able to use VBA to copy that row.
@archanaaa2514
@archanaaa2514 4 жыл бұрын
Hi sir, is vba is more demand or python? Which is useful most in future?
@ChesterTugwell
@ChesterTugwell 4 жыл бұрын
Python
@IvanCortinas_ES
@IvanCortinas_ES 3 жыл бұрын
Calculate doesn't work smoothly. Sometimes it does not update !!
How to Apply BLINKING Conditional Formatting in Excel
6:11
Chester Tugwell
Рет қаралды 28 М.
Highlighting Cells Based On Value/Text - Excel VBA
10:00
Data Nik
Рет қаралды 19 М.
That's how money comes into our family
00:14
Mamasoboliha
Рет қаралды 12 МЛН
WHAT’S THAT?
00:27
Natan por Aí
Рет қаралды 12 МЛН
КАК ДУМАЕТЕ КТО ВЫЙГРАЕТ😂
00:29
МЯТНАЯ ФАНТА
Рет қаралды 8 МЛН
Sum Cells Based on Their Color in Excel (Formula & VBA)
12:18
TrumpExcel
Рет қаралды 129 М.
How to Use the IFS Function in Excel
11:01
Leila Gharani
Рет қаралды 341 М.
Uncover Hidden Excel Powers: Sum & Count Cells by Color!
9:36
Excel VBA IF THEN Statement (with ELSEIF & Looping in cells)
12:10
Leila Gharani
Рет қаралды 313 М.
Create a Filter as You Type SEARCH BOX in Excel VBA
15:11
Chester Tugwell
Рет қаралды 55 М.
5 Excel Secrets You'll Be Embarrassed You Didn't Know
17:32
Excel Campus - Jon
Рет қаралды 110 М.
How to Sum Cells by Color in Excel (Get it to update automatically)
10:54
How To Count Colors with an Excel Function | Count Colored Cells
4:56
smart appliances! new gadgets, versatile utensils, tool items #shorts #gadget
0:10
Pretty Balloon Family
Рет қаралды 50 МЛН
Handcraft a Simple Trigger mechanism # Craft Idea # DIY # Bamboo Slingshot
0:13
LTL Homemade ideas DIY
Рет қаралды 13 МЛН
Купили новый бассейн 🔥
0:58
Мини босс Марк и Мирон
Рет қаралды 3,3 МЛН
Ném bóng coca-cola😂😂😂
0:35
Tippi Kids TV
Рет қаралды 33 МЛН