A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Modify and delete outlook tasks



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old July 16th 07, 04:01 PM posted to microsoft.public.outlook.program_vba
[email protected]
external usenet poster
 
Posts: 2
Default Modify and delete outlook tasks

Hello,
using excel VBA I send task planning to my colleagues.
Sometimes I need to update the task or to delete it but i'm not able.
My code lines a
-----
Sub DeleteTaxDayShared()
Dim objOL As Outlook.Application
Dim objNS As Outlook.Namespace
Dim strFind As String
Dim objCalFolder As Outlook.MAPIFolder
Dim colCalendar As Outlook.Items
Dim objAppt As Outlook.TaskItem
Dim myRecipient As Outlook.Recipient

Set objOL = CreateObject("Outlook.Application")
Set objNS = objOL.GetNamespace("MAPI")
Set myRecipient = ")
myRecipient.Resolve
If myRecipient.Resolved Then
Set objTaskFolder =
objNS.GetSharedDefaultFolder(myRecipient,olFolderT asks)
Set colTask = objTaskFolder.Items
strFind = "[Subject] = " & Chr(34) & "Tax Day" & Chr(34)
Set objTask = colTask.Find(strFind)
If Not objTask Is Nothing Then
objTask.Delete
End If
End If
Set objOL = Nothing
Set objNS = Nothing
Set objCalFolder = Nothing
Set colCalendar = Nothing
End Sub
-----
I receive runtime error on:
Set objTaskFolder = objNS.GetSharedDefaultFolder(myRecipient,
olFolderTasks)

Thanks.

Ads
  #2  
Old July 16th 07, 11:11 PM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Modify and delete outlook tasks

Do you have permissions to open that Tasks folder? Can you do it using the
UI?

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


wrote in message
ps.com...
Hello,
using excel VBA I send task planning to my colleagues.
Sometimes I need to update the task or to delete it but i'm not able.
My code lines a
-----
Sub DeleteTaxDayShared()
Dim objOL As Outlook.Application
Dim objNS As Outlook.Namespace
Dim strFind As String
Dim objCalFolder As Outlook.MAPIFolder
Dim colCalendar As Outlook.Items
Dim objAppt As Outlook.TaskItem
Dim myRecipient As Outlook.Recipient

Set objOL = CreateObject("Outlook.Application")
Set objNS = objOL.GetNamespace("MAPI")
Set myRecipient = ")
myRecipient.Resolve
If myRecipient.Resolved Then
Set objTaskFolder =
objNS.GetSharedDefaultFolder(myRecipient,olFolderT asks)
Set colTask = objTaskFolder.Items
strFind = "[Subject] = " & Chr(34) & "Tax Day" & Chr(34)
Set objTask = colTask.Find(strFind)
If Not objTask Is Nothing Then
objTask.Delete
End If
End If
Set objOL = Nothing
Set objNS = Nothing
Set objCalFolder = Nothing
Set colCalendar = Nothing
End Sub
-----
I receive runtime error on:
Set objTaskFolder = objNS.GetSharedDefaultFolder(myRecipient,
olFolderTasks)

Thanks.


  #3  
Old July 17th 07, 08:19 AM posted to microsoft.public.outlook.program_vba
[email protected]
external usenet poster
 
Posts: 2
Default Modify and delete outlook tasks

I don't know.
I don't know Outlook very well, I'm an excel user.
I supposed to have the permission due to the fact that I sent the taks
to colleagues.
the runtime error is -71286782 (fbc04002) that I'm not able to
address.
If the way I choose is wrong, please give me a suggestion.
I'm able to delete or postpone appointment, why I couldn't do the same
with tasks?


  #4  
Old July 17th 07, 03:30 PM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Modify and delete outlook tasks

You need to find out what permissions you have on that other mailbox, I
can't do that for you. The owner of the mailbox needs to look at the
delegate permissions that are installed, or your Exchange admins need to do
that.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


wrote in message
ups.com...
I don't know.
I don't know Outlook very well, I'm an excel user.
I supposed to have the permission due to the fact that I sent the taks
to colleagues.
the runtime error is -71286782 (fbc04002) that I'm not able to
address.
If the way I choose is wrong, please give me a suggestion.
I'm able to delete or postpone appointment, why I couldn't do the same
with tasks?



 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Tasks categories. Unable to modify another user's categories. Tommy Outlook - Installation 0 August 9th 06 05:43 PM
how to delete overdue tasks/reminders? jon Outlook - General Queries 1 August 3rd 06 05:53 PM
How to delete all calender,tasks,notes,contacts from outlook? Paul L Outlook - General Queries 1 May 1st 06 06:12 PM
How do I modify Delete button to also mark item as read? [email protected] Outlook and VBA 1 April 24th 06 07:14 AM
User cannot edit or delete tasks Micheline Outlook - Installation 0 February 15th 06 11:35 PM


All times are GMT +1. The time now is 10:17 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.