vba - Email Notification from MS Project using VB macro -


I would like an email notification from MS Project, whenever the previous work has been completed. I want to email it to the predefined resource and the project manager. I do not know where I start from.

"Send email" means you want to send an email through Outlook, You can use the method. MS Project does not have work-level events but you can use Project_Change events; All you need to do is loop through all the tasks which need to be sent.

In this example, I store the recipient's email address in the hyperlink field and I demonstrate whether an email has already been sent or not, this flag uses 1 field. The user has left the email for review before clicking the send button; Except for this, the pop-up message is avoided where the user should get access to programmatic access to Outlook. Private Sub Project_Change (By Piece As Project) Outlook.Application in default for Outlook.MailItem ActiveProject.Tasks for each TSK if tsk.PercentComplete = 100 and not tsk.Flag1 then If OL is not anything then set AL = getObject (, "Outlook.Application") for each succ set in Tsk.SuccessorTasks mail = ol.CreateItem (olMailItem) mail.To = tsk.Hyperlink mail.Subject = "A predecessor is completed" mail. Body = "work" & amp; TISK .ID & amp; "The predecessor of your work" & amp; Succ.ID & amp; "Done." Mail.Display the next succ tsk.flag1 = true end if the next TSK and sub

Note: Be sure to add the MS Outlook Object Library reference.

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

jasper reports - How to center align barcode using jasperreports and barcode4j -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -