Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 09-05-2024, 06:28 AM
Marcia's Avatar
Marcia Marcia is offline VBA to change the font if condition is met Windows 11 VBA to change the font if condition is met Office 2021
Expert
VBA to change the font if condition is met
 
Join Date: May 2018
Location: Philippines
Posts: 551
Marcia has a spectacular aura aboutMarcia has a spectacular aura aboutMarcia has a spectacular aura about
Default VBA to change the font if condition is met

Hi. I would like help in making a formula into a vba code.



In D5 until AH105 of "DTR Monitor" sheet, I would like to populate it with the following formula through a vba code.
Code:
Sub DTR_Monitor()

Dim WS As Worksheet

Set WS = Worksheets("DTR Monitor")

WS.Range("D5").Formula =_
IF(INDEX(Time,MATCH([@[Name of Employee]],Name,0),MATCH(D$4,DateMonitor,0)) is a number, enter "P" then change the font from Calibri to Wingdings2 (A check mark is the result).
Else, INDEX(Time,MATCH([@[Name ofEmployee]],Name,0),MATCH(D$4,DateMonitor,0)), retain the calibri font

End Sub
Thank you for the usual help.
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
VBA to change the font if condition is met VBA - Word how to globally change the font and font size in footnotes thomasoj Word VBA 3 01-15-2020 06:26 AM
Condition Icon setting help _ signage doesn't change Haha88 Excel 2 02-17-2019 09:53 AM
VBA to change the font if condition is met Looping Macro to Change Font, Font Size, and Give Heading 1 WH7262 Word VBA 1 08-26-2014 03:46 PM
VBA to change the font if condition is met (Excel 2007) Need help with colour change when condition met in drop down list oalrashdan Excel Programming 1 12-13-2013 02:21 AM
VBA to change the font if condition is met Make Font Dropdown Change All Styles' Font trevorhiller Word 1 04-14-2012 02:14 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 01:19 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft