Skip to content
- Excel VBA Cell Background Color: Fill Cells in CodeTo change a cell’s background color with Excel VBA, set its Interior.Color property—for example, Range("A1").Interior.Color = RGB(255, 255, 0) fills A1 yellow.…VBA & macros
- Excel VBA Select Case Examples: Syntax and Common UsesIn Excel VBA, Select Case chooses which block of code to run based on the value of an expression. Use it when…VBA & macros
- Excel VBA: Stop on Error or Cancel a Running MacroTo stop an Excel VBA macro when an error occurs, let the error remain unhandled or use an error handler that reports…VBA & macros
- Excel VBA Automation Error: Causes, Fixes, and Checks“Excel VBA Automation error: Exception occurred” is a broad error from an object that VBA is controlling, often another Office app or…VBA & macros
- Excel VBA: How to Assign a Keyboard Shortcut to a MacroTo assign a keyboard shortcut in Excel for Microsoft 365 on Windows, press Alt+F8, select the macro, choose Options, enter a letter…VBA & macros
- Excel VBA Application-Defined or Object-Defined ErrorIn Excel VBA, “Application-defined or object-defined error” is usually runtime error 1004: Excel could not complete an operation requested through its object…VBA & macros
- Excel VBA Application-Defined Error: Causes and FixesAn Excel VBA “application-defined or object-defined error” is usually a runtime error 1004: Excel could not carry out an operation requested by…VBA & macros
- Excel VBA Advanced Filter: Using Multiple CriteriaTo use multiple criteria with Excel VBA Advanced Filter, put conditions that must all be true on the same criteria row, and…VBA & macros
- Excel VBA: Add a New Worksheet with a Specific NameTo add a worksheet and give it a name with Excel VBA, add the sheet, then set its Name property. This example…VBA & macros
- Excel VBA: Add a New Sheet at the End and Name It SafelyTo add a worksheet after the workbook’s last tab and name it in Excel VBA, use Worksheets.Add with the last item in…VBA & macros
- Excel VBA: Add a New Sheet and Rename It AutomaticallyTo add a worksheet and give it a name with Excel VBA, use Worksheets.Add to create the sheet, then assign its Name…VBA & macros
- Excel VBA: Add a Keyboard Shortcut to a MacroYes. In Excel for Microsoft 365 on Windows, open Developer > Macros, select your macro, choose Options, and enter a letter to…VBA & macros
- Excel VBA: Sum Cells by Fill ColorIf by “add cells” you mean total their numbers, a VBA macro can sum values in a range when each cell’s fill…VBA & macros
- Excel VBA: Add Cells With Fill ColorTo insert a cell and give it a fill color with VBA, use the cell’s Insert method, then set its Interior.Color property.…VBA & macros
- Excel Value Comparison Formula: Examples and OptionsIn Excel, compare two values with =A2=B2: it returns TRUE when the values match and FALSE when they do not. To test…Formulas & functions
- Excel Data Validation from a List: Setup and TroubleshootingYes. In Excel for Microsoft 365 on Windows, select the cells, choose Data > Data Validation, set Allow to List, and enter…How-to basics
- Excel Table Names in Formulas: How to Use Them WellYes. In Excel for Microsoft 365 on Windows, use a table name and its column header in a structured reference, such as…Formulas & functions
- Excel Pivot Table Data in Formulas: How to Use ItYes. In Excel for Microsoft 365, use GETPIVOTDATA to retrieve a value from a PivotTable by its field names and items, or…Charts & pivot tables
- Excel SUMIFS With Multiple Criteria: A Practical GuideWith sales in D2:D7, regions in B2:B7, and products in C2:C7, use =SUMIFS(D2:D7,B2:B7,"East",C2:C7,"Tea") to add sales where the region is East and…Formulas & functions
- Excel COUNTIFS: How to Count Rows With OR ConditionsCOUNTIFS uses AND logic between its criteria pairs: a row must meet every condition you give it. To count rows that meet…Formulas & functions
- Excel Named Ranges: How to Create and Use ThemTo use named ranges in Excel, assign a descriptive name to a cell or range, then use that name in formulas instead…How-to basics
- Excel Named Ranges in Formulas: How to Use ThemYes. Excel lets you use a named range in a formula just like a cell reference: if the name Sales refers to…Formulas & functions
- Excel Area Charts: How to Shade Selected SectionsYes. In Excel for Microsoft 365 on Windows, you can shade selected sections of an area chart by adding a helper data…Charts & pivot tables
- Excel Uppercase to Lowercase Shortcut: What Actually WorksExcel has no built-in keyboard shortcut that directly changes selected text from uppercase to lowercase. The reliable method is to enter =LOWER(A2)…How-to basics
- Excel Unmerge Cells Shortcut: Keys, Steps, and FixesIn Excel for Microsoft 365 on Windows, select a merged cell and press Alt, H, M, U—one key after another, not all…How-to basics
- Excel Unmerge Cells and Fill Every Cell with Its DataTo unmerge cells in Excel for Microsoft 365 on Windows, select the merged range and choose Home > Merge & Center >…How-to basics
- Excel Unique Values Without Duplicates: Methods That WorkTo show each value once in Excel, use the UNIQUE function: with a list in A2:A7 containing Apple, Pear, Apple, Plum, Pear,…Formulas & functions
- Excel Unique List Without Duplicates: How to Make OneTo make a unique list in Microsoft Excel for Microsoft 365 on Windows, enter =UNIQUE(A2:A100) in an empty cell, replacing the range…Formulas & functions
- Excel Undo Shortcut: Ctrl+Z and How It WorksIn Excel for Microsoft 365 on Windows, press Ctrl+Z to undo your most recent action; on a Mac, press Command+Z. Press the…How-to basics
- Excel UNIQUE Function: Return Values Without DuplicatesYes. In Microsoft 365 for Windows, enter =UNIQUE(A2:A100) to return the distinct values in A2:A100, with repeated entries appearing only once. The…Formulas & functions