Exporting tasks from Outlook

Jump to FAQ
There are two ways to export tasks from Outlook in a format suitable for importing into Google Tasks using Google Tasks Import.
  1. Using the Export Outlook Tasks tool
  2. Using a custom [Export Tasks] button in Outlook
The end result from both methods is the same - a file that can be imported by Google Tasks Import. The primary differences are;
Export Outlook Tasks tool Custom [Export Tasks] button in Outlook
Program is run from the Start menu Button allows a user to export tasks directly from within Outlook
Easy to install More complicated installation procedure
Requires user to program installation privelege on PC Requires user to have access to the VBA environment in Outlook
Provides more tasklist name import options
  • Use category as tasklist name
  • Import all tasks into default tasklist
  • Import all tasks into user-specified tasklist name
  • Multiple options for specifying tasklist name if task has no categories
Limited tasklist name import options;
  • Use category as tasklist name
  • Import all tasks into default tasklist
  • Import all tasks into tasklist named "Outlook"

A. Exporting tasks using the Export Outlook Tasks tool

If the Export Outlook Tasks tool has not been installed, follow these instructions.
  1. Outlook does not need to be running to export tasks using Export Outlook Tasks
    • Due to a quirk in the interaction between Export Outlook Tasks and Outlook, some windows may appear behind other windows. Minimising or closing Outlook before starting Export Outlook Tasks may help.
  2. Start Export Outlook Tasks from the start menu
  3. Select the desired tasklist name options. This determines the tasklist name(s) to be used when the tasks are imported into Google Tasks.
  4. Select which tasks to export. Only tasks with the selected status values will be exported.
  5. Click [Choose tasks folder], then choose the tasks folder to export and click [OK]
  6. The "Save As" window opens automatically
  7. Choose the location to save the exported CSV file and click [Save]
  8. Outlook may display a message such as
    A program is trying to access email addresses you have stored in Outlook. Do you want to allow this?
    • This is a misleading message from Outlook, as Export Outlook Tasks is accessing Tasks not email addresses.
    Select
    Allow access for 1 minute
    and click [Yes] to allow the export to continue.
  9. Export Outlook Tasks starts retrieving tasks from Outlook and writes the tasks to the file chosen in the previous step.
    • The amount of time taken to export the tasks depends on how many tasks are in the select tasks folder, but should take less than one minute. The bottom of the Export Outlook Tasks window displays when the export is complete.
  10. A window will display when the export has completed, showing the file name of the exported file. For convenience, this filename is also copied to the clipboard so that it can easily be pasted in step 10.
  11. Go to the Google Tasks Import website
  12. Choose the desired import method. The recommended import methods for Outook tasks are:
    • Append timestamp to tasklist name, or
    • Append own suffix, or
    • Replace tasklist contents
    For more details of each method, click on the help icon next to each option on the website.
  13. Click on the file upload button. When the "Open file" window opens, you can paste the filename, or browse to the location where the file was saved.
    • The name of the file upload button varies from browser to browser. For example, Firefox and Internet Explorere use [Browse ...], whereas Chrome uses [Choose file]

B. Exporting tasks using the custom [Export Tasks] button in Outlook

If the custom [Export Tasks] button has not been installed in Outlook, follow the instructions below.
  1. From Outlook, Click the [Export Tasks] button
  2. Choose the Import Mode
  3. Choose status values to be exported. This determines which tasks will be exported (e.g., only incomplete tasks)
  4. Click on [Choose tasks folder]
  5. Choose the tasks folder to be exported and click [OK]
    • Note that the displayed list will show the default inbox highlighted. Scroll up or down to find the desired tasks folder
  6. Choose a location to save the exported file and click [OK]
    • The script will automatically create a unique file name which includes the name of the tasks folder, and today's date and time. For example "tasks_export My Work Tasks 2012-10-19 15-39-24.csv"
  7. A window will display when the export has completed, showing the file name of the exported file. For convenience, this filename is also copied to the clipboard so that it can easily be pasted in step 10.
  8. Go to the Google Tasks Import website
  9. Choose the desired import method. The recommended import methods for Outook tasks are:
    • Append timestamp to tasklist name, or
    • Append own suffix, or
    • Replace tasklist contents
    For more details of each method, click on the help icon next to each option on the website.
  10. Click on [Choose file]. When the "Open file" window opens, you can paste the filename, or browse to the location where the file was saved


Installation Instructions


Installing Export Outlook Tasks tool

  1. Extract the ExportOutlookTasks_Setup folder from ExportOutlookTasks_Setup.zip to a suitable temporary location.
    • If reinstalling, make sure that you extract to the same temporary folder location initially used. If you cannot remember the initial folder location, uninstall Export Outlook Tasks tool before installing the new version.
  2. Open the extracted folder and run setup
    • Do not attempt to run setup from within the Zip program, as the install may fail. Make sure that setup is run only from the extracted folder.
  3. Click [Install]
    • The installer will display Publisher cannot be verified because, this project is unfunded, so there is no money to pay for a certificate.
  4. The installation will only take a few seconds. When it is complete, the Export Outlook Tasks window opens.
  5. The installation creates an entry for Export Outlook Tasks in Start > All Programs
If you attempt to reinstall Export Outlook Tasks from a different intall location, you may see the following error message;
You cannot start application Export Outlook Tasks from this location because it is already installed from a different location.
In this case, just uninstall Export Outlook Tasks first, using the standard Windows program uninstall option in the Control Panel.

Installing [Export Tasks] button on Outlook toolbar

These instructions are for Microsoft Outlook 2007. The code should work for other Outlook versions, but the setup instructions may differ.
  1. Extract the contents of the ExportTasksFromOutlook.zip file to a location where they will not be deleted, edited or moved.
  2. From Outlook, press Alt+F11 to open the Visual Basic Editor
  3. Click on File > Import file ... and navigate to the location chosen in step 1
  4. Select CListOfTasks.cls and click [Open]
  5. Repeat step 3 and open FormExportTasks.frm
  6. Click on Tools > References to open the "References - VBAProject" window and ensure that the following have all been selected:
    • Visual Basic for Applications
    • Microsoft Outlook vv.v Object Library {where vv.v is the highest version number}
    • Microsoft Scripting Runtime
    • Microsoft Forms 2.0 Object Library
    It is OK if other references are selected as well
  7. In the project map on the left hand side, under "Microsoft Office Outlook Objects", double click on ThisOutlookSession
  8. In the (General) workspace, on the right hand side, type (or paste) the following code
    Public Sub ExportTasksAsUnicode()
        formExportTasks.Show
    End Sub
    
  9. Click File > Save
  10. Close the Visual Basic Editor window
  11. On the main Outlook window, right-click anywhere on the toolbar, and choose Customize
  12. On the Customize window, from the Commands tab, choose the Macros category
  13. Click and drag Vbaproject.ThisOutlookSession.ExportTasksAsUnicode to a suitable location on the toolbar
    • The first part of the name may sometimes appear as Project1 or similar
      e.g., Project1.ThisOutlookSession.ExportTasksAsUnicode
  14. Right-click on the newly created button and select all the text in the Name: field and replace it with   Export Tasks
  15. Close the Customize window
  16. Exit Outlook
  17. Restart Outlook
When Outlook restarts, and/or when the [Export Tasks] button is clicked, Outlook may display a warning message.
If you see this warning, Click [Enable Macros]
If nothing happens when the [Export Tasks] button is clicked, that is probably due to Outlook's Macro Security settings. There are two solutions;
  1. Reduce security limitations to allow macros to run
    • This option is easier, but does slightly reduce security. Follow steps 101 through 106.
  2. Create a self-signed digital certificate
    • This option is recommended to maintain security. Follow steps 201 through 215.

Option (a) - Reduce security limitations to allow macros to run

  1. Open the Macro Security setting from Tools > Macro > Security ...
  2. Ensure that Macro Security is set for Warnings for all macros
    • In older versions of Outlook, the options are High, Medium or Low. Choose Medium
  3. Exit Outlook
    • Click [Yes] if prompted "Do you want to save the VBA project 'VbaProject.OTM'?
  4. Restart Outlook
  5. When Outlook restarts, and/or when the [Export Tasks] button is clicked, Outlook will display a warning message.
    • Newer versions of Outlook will display Microsoft Office has identified potential security concerns
    • Older versions of Outlook will display 'ThisOutlookSession' contains macros.
  6. Click [Enable Macros]
[Export Tasks] should now work. You may be prompted to click the [Enable Macros] button every time that you restart Outlook, and/or the first time that you click the [Export Tasks] button.

Option (b) - Create a self-signed digital certificate

  1. Go to Start > All programs > Micosoft Office > Microsoft Office Tools > Digital Certificate for VBA Projects
  2. Create a self-signed digital certificate with a suitable name such as "My VBA Certificate"
  3. From Outlook, press Alt+F11 to open the Visual Basic Editor
  4. Click on Tools > Digital Signature
  5. Click [Choose] and click on the certificate created in step 202, then click [OK] and [OK] again
  6. Click on File > Save VbaProject.OTM
  7. Close the Visual Basic Editor window
  8. On the main Outlook window, click on Tools > Macro > Security ...
  9. Ensure that Macro Security is set for Warnings for signed macros; all unsigned macros are disabled
  10. Exit Outlook
  11. Click [Yes] when prompted "Do you want to save the VBA project 'VbaProject.OTM'?
  12. Restart Outlook
  13. On the "Microsoft Office Outlook Security Notice" window, there should be warning stating that the publisher has not been authenticated for ThisOutlookSession.
  14. Click on Show Signature Details to confirm that the name is the same as set in step step 202 and click [OK]
  15. Click [Trust all documents from this publisher]
Please report any problems at code.google.com/p/import-tasks/issues/list


FAQ


Why is a separate program or script required?

It was necessary to create a script or program that runs on the user's PC, because the export file from Outlook often cannot be reliably imported by other applications. There are 3 major issues which prevent a web application being able to reliably import tasks directly exported from Outlook; very poor support for non-English characters, ambiguous date formatting, and column names that vary by locale.

File format

Outlook exports tasks in Windows ANSI format. Windows ANSI relies on codepages to handle non-ASCII extended and interantional characters. In order to be able to interpret the contents of a Windows ANSI file, the reader must know which code page was used when the file was written. Unfortunately, the file does not indicate which code page was used. Without that information, the file can only be correctly interpreted on a machine using exactly the same code page as the machine that created the file (i.e., people in the same locale). Since AppEngine has no way to know which code page was used, it cannot not process files with any non-ASCII text (i.e., extended or international characters).
Another limitation of the Windows ANSI format is that it can support only one extended character set in any given file. So, even if we knew what code page had been used, if a user had used more than one language or extended character set, the text for one of those languages would be displayed as garbage anyway.

Date format

Another problem with the Outlook tasks export file is that the date is stored according to the settings on the user's PC, which varies by locale, but can also be set to a custom format by the user. This makes it very difficult for a third-party to determine what the intended date was. For example, in the U.S.A, 3/8/2012 would be interpretted as 8 March 2012, however in many other regions such as Europe and Australia, this would be interpretted as 3 August 2012. There are many other date formats used worlwide, including some that use characters between values rather than symbols. See http://en.wikipedia.org/wiki/Date_format_by_country for an idea of the variability of date formats.

International column names

In many countries, Outlook exports column names that correspond to the locale the user is in. For example, in German Outlook, "Subject" is exported as "Betreff"

The solution

The program or VBA scrip handles all these issues by using the column names expected by Google Tasks Import, by exporting dates in an unambiguous format, and then using the UTF-8 file format (which handles all extended and international characters). The program is able to correctly interpret the tasks data, because it is running on the user's PC and can query Outlook directly, thus avoiding having to try to interpret ambiguous data.

How does the program work?

The program queries Outlook, and retrieves all the tasks from the chosen tasklist. The program then exports the file as a UTF-8 standard file with unambigous date format, which maintains all extended and international characters, and ensures that dates are correctly interpretted, irrespective of the user's own date format.