Solved

Clear Categories on When Assigning Task or Rule that does the same

Posted on 2014-02-12
9
344 Views
Last Modified: 2014-03-07
In Outook 2010 I have several tasks which have been assigned a category named "Docket Sheets *".  I have an Outlook View that filters on this category.

Sometimes I assign many of these tasks to someone else.  I need to be able to have this category removed from the task for the recipient when I assign the task or I need to be able to write a rule in the recipients mailbox that will clear the category when they receive it.

The "Clear categories on mail (recommended)" rule does not work.
0
Comment
Question by:Senniger1
  • 4
  • 3
9 Comments
 
LVL 76

Expert Comment

by:David Lee
ID: 39855845
Hi, Senniger1.

This cannot be done with a rule.  Rules only work against messages and meeting requests/updates.  They do not work against task requests.  I can remove the category, but doing that requires using a macro.  If a macro is acceptable, then let me know and I'll post the code and instructions for using it.
0
 

Author Comment

by:Senniger1
ID: 39856146
I'm open to a macro so yes, please post.

Thank you!
0
 
LVL 76

Expert Comment

by:David Lee
ID: 39856177
Here's the code.  Follow these instructions to add it to Outlook.

1.  Start Outlook
2.  Press ALT+F11 to open the Visual Basic Editor
3.  If not already expanded, expand Microsoft Office Outlook Objects and click on ThisOutlookSession
4.  Copy the code from the Code Snippet box and paste it into the right-hand pane of Outlook's VB Editor window
5.  Edit the code as needed.  I included comment lines wherever something needs to or can change
6.  Click the diskette icon on the toolbar to save the changes
7.  Close the VB Editor
8.  Click File and select Options
9.  Click Trust Center
10. Click the Trust Center Settings button
11. Click Macro Settings
12. Change the Macro Settings to "Notifications for all macros"
13. Click OK
14. Click OK
15. Close Outlook
16. Start Outlook.  Outlook will display a dialog-box warning that ThisOutlookSession contains macros and asking if you want to allow them to run.  Say yes.

Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)
    Dim olkTsk As Outlook.TaskItem
    If Item.Class = olTaskRequest Then
        Set olkTsk = Item.GetAssociatedTask(False)
        olkTsk.Categories = ""
        olkTsk.Save
    End If
End Sub

Open in new window


When you assign a task to someone, Outlook creates and sends the recipient a task request.  The code works by watching for these outgoing task requests.  When it sees one, it gets the task associated with that task request and removes its categories.
0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 

Author Comment

by:Senniger1
ID: 39859150
First of all, thank you so much for the detail and I totally liked the concept you proposed.

I followed your instructions.  When I assign a task, it is removing the category from MY tasklist and the recipient I've assigned the task to is still getting a task with a category.

I want the task in my tasklist to keep the category.  However, when I assign a task that has one of my categories, I don't want the recipient of the task to get a task with a category.

If I'm not explaining well, please let me know.
0
 
LVL 76

Accepted Solution

by:
David Lee earned 500 total points
ID: 39881321
Senniger1

Sorry to be so slow to get back to you.  I don't know how it's possible for the assignee to get a task with the category when the category was removed prior to the task request going out.  I'm not doubting that's what's happening, but I don't see how it's possible unless you've added a category between the time the request was sent and the assignee accepted it.  

It's not possible for the assignee to have something different than what you have.  You are essentially sharing a copy of the task.  If you have categories, then the assignee will also have categories.  If you want the assignee to not have any categories, then your copy of the task can't have categories.
0
 

Author Closing Comment

by:Senniger1
ID: 39912205
Thank you for the information and your assistance.
0
 
LVL 76

Expert Comment

by:David Lee
ID: 39912604
You're welcome!
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

Sometimes Outlook might have problems sending a message. There may be various causes- corrupted PST, AV scanner etc. The message, instead of going to the Sent Items folder, sits in the Outbox indefinitely. To remove it you can use a free tool cal…
Outlook Free & Paid Tools
To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…
CodeTwo Sync for iCloud (http://www.codetwo.com/sync-for-icloud?sts=6554) automatically synchronizes your Outlook 2016, 2013, 2010 or 2007 folders with iCloud folders available via iCloud Control Panel. This lets you automatically sync them with…

910 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

22 Experts available now in Live!

Get 1:1 Help Now