How to highlight whole numbers in Excel?
Supposing, there are both integers and decimals in your worksheet, and now, you would like to apply the conditional formatting to stand out the whole numbers in your worksheet. Have you ever tried to solve this task by yourself? Today, I will tell you a useful formula to finish this job.
- Reuse Anything: Add the most used or complex formulas, charts and anything else to your favorites, and quickly reuse them in the future.
- More than 20 text features: Extract Number from Text String; Extract or Remove Part of Texts; Convert Numbers and Currencies to English Words.
- Merge Tools: Multiple Workbooks and Sheets into One; Merge Multiple Cells/Rows/Columns Without Losing Data; Merge Duplicate Rows and Sum.
- Split Tools: Split Data into Multiple Sheets Based on Value; One Workbook to Multiple Excel, PDF or CSV Files; One Column to Multiple Columns.
- Paste Skipping Hidden/Filtered Rows; Count And Sum by Background Color; Send Personalized Emails to Multiple Recipients in Bulk.
- Super Filter: Create advanced filter schemes and apply to any sheets; Sort by week, day, frequency and more; Filter by bold, formulas, comment...
- More than 300 powerful features; Works with Office 2007-2019 and 365; Supports all languages; Easy deploying in your enterprise or organization.
To highlight only the integers in your worksheet, you can use the following formula in the conditional formatting, please do with these:
1. Select the range that you want to highlight the whole numbers.
2. Click Home > Conditional Formatting > New Rule, see screenshot:
3. In the New Formatting Rule dialog box, click Use a formula to determine which cells to format option under Select a Rule Type: list box, and then enter this formula =IF(LEN(A1),MOD(A1,1)=0,"") into the Format values where this formula is true: text box, (A1 is the first cell of your selection, you can change it as you need), see screenshot:
4. Then click Format button to open the Format Cells dialog, and choose one color you like under Fill tab, see screenshot:
5. And then click OK > OK to close the dialogs, and the whole numbers in your selected range have been highlighted with the color you choose.
1. If you want to highlight the decimals in the range only, you should apply this formula =MOD(A1,1)>0 within the Conditinal Formatting feature in above step 3.
2. Conditional Formatting tool is a dynamic function, the highlighted color will be adjusted with the changes of your number.