Create Hyperlink in Excel to open Task imported from Outlook

robfoster2000

New Member
Joined
Dec 14, 2009
Messages
8
Hi All.

I have some code to import all non-completed tasks from Outlook into a spreadsheet. My plan is to then put these into some kind of Eisenhower matrix to allow better organising of important vs urgent tasks etc.
I want each task to be a hyperlink which will then open the task in Outlook. I have read that this is possible by using the GUID of the Task object and the simply creating a hyperlink with "Outlook:[GUID]".
However, when looping through the items in the task list, the objects do not have a GUID reference as they are TaskItem objects and not Task objects.
According to Microsoft references, the Task object has a property "GUID", but the TaskItem object does not. Hence I can't create the hyperlink to directly open the task. The TaskItem does have a "Display" method, but I don't want to have to write additional code to find the task and call this when it is clicked on.

I retrieve the task items with the following:

Set olNS = olApp.GetNamespace("MAPI")
Set myTaskItems = olNS.GetDefaultFolder(olFolderTasks).Items

Any help to find a way to programatically add a hyperlink which will open the task in outlook would be much appreciated!

Cheers all!
Rob.
 

Excel Facts

Create a chart in one keystroke
Select the data and press Alt+F1 to insert a default chart. You can change the default chart to any chart type

Forum statistics

Threads
1,147,518
Messages
5,741,638
Members
423,675
Latest member
Dea21

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top