Solved

Changing font for task that are 100% complete Automatically

Posted on 2011-09-13
5
2,328 Views
Last Modified: 2012-05-12
I would like to setup something in MS project that would automatically change font to gray color when i complete task to 100%. also if i would like to switch it back to normal if somereason it is changed back from 100% to anything less then that... is that possible?
0
Comment
Question by:dharmesh_a
  • 2
5 Comments
 
LVL 15

Accepted Solution

by:
lyonst earned 500 total points
ID: 37095256
Just insert and run this Macro

Sub Test()
Dim tsk As Task
For Each tsk In ActiveProject.Tasks
    If Not tsk Is Nothing Then
        If tsk.PercentComplete = 100 Then
            SelectTaskField Row:=tsk.ID, _
                      RowRelative:=False, Column:="Name"
            'Font Bold:=True, Color:=pjRed
            Font32Ex CellColor:=&HF0D9C6
        End If
        If tsk.PercentComplete <> 100 Then
            SelectTaskField Row:=tsk.ID, _
                      RowRelative:=False, Column:="Name"
            'Font Bold:=True, Color:=pjRed
            Font32Ex CellColor:=&HFFFFFF
        End If
    End If
Next
End Sub

You can Set up a Shortcut to Run it..
0
 
LVL 15

Expert Comment

by:lyonst
ID: 37095354
Can also use

Font Bold:=True, Color:=pjGray

Instead of Font32Ex CellColor:=&HF0D9C6

Or Red as on the example that is commented out
0
 
LVL 17

Expert Comment

by:xtermie
ID: 37103454
You can then use the macro either as a BUTTON on a custom toolbar which you can run anytime you want, or set it on the OnOpen or OnClose or OnUpdate or OnSave events of the file, so that the formatting is down automatically...the sub may need some tweaking though...can you post a small sample of a project?
0
 
LVL 29

Expert Comment

by:leonstryker
ID: 37242390
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Art of Relay Sprinting: A Sprinter's Philosophy on Scrum If Agile is the quarter-mile race to value, Scrum is the art of the mile relay — taking a baton from a business partner and combining sprints to achieve team success. Consequently, the key…
5 Tips For Long Jumpers: A Sprinter's Approach to Agile Software Development As a Sprinter, long jumping — applying momentum to progress by leaps and bounds — is a natural and complementary skill. In the following article, I will share my five ti…
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…
Both in life and business – not all partnerships are created equal. As the demand for cloud services increases, so do the number of self-proclaimed cloud partners. Asking the right questions up front in the partnership, will enable both parties …

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now