Cannot Export Microsoft Project XML Files in Primavera P6 Professional, Receive Error: An Exception Occurred While Initializing Module 'CommandLineModule'. The Exception Message Was: The Given Key Was Not Present in the Dictionary." (Doc ID 2169879.1)

Last updated on JANUARY 12, 2017

Applies to:

Primavera P6 Professional Project Management - Version 16.1.0.0 and later
Information in this document applies to any platform.

Symptoms

On : P6 Project Management Client

When attempting to Export a Project via MS XML Project, the following error occurs:

ERROR:
-----------------------
Prism.Modularity.ModuleInitializeException: An exception occurred while initializing module 'CommandLineModule'.
  - The exception message was: The given key was not present in the dictionary.
  - The Assembly that the module was trying to be loaded from was:Primavera.Mercury.CommandLineModule, Version=16.1.0.18077, Culture=neutral, PublicKeyToken=null
  Check the InnerException property of the exception for more information. If the exception occurred while creating an object in a DI container, you can exception.GetRootException() to help locate the root cause of the problem.
  ---> System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary.
  at System.Collections.Generic.Dictionary`2.get_Item(TKey key)
  at Primavera.Domain.Base.Calendar.CreateExceptionDaysFromData(String data)
  at Primavera.Domain.Base.Calendar.get_ExceptionDays()
  at Primavera.Venus.Data.FileStore.ApiXmlCalendarDataExport.ExportCalendarData(Calendar calendar, XmlElement CalNode)
  at Primavera.Venus.Data.FileStore.ApiXmlExtraObjects.HandleExtraObjects(Entity anEntity, XmlElement aNode)
  at Primavera.Venus.Data.FileStore.ApiXmlProjectExporter.ExportOneEntity(Entity anEntity, IEntityMetadata metaData, XmlElement root, WBS rootwbs)
  at Primavera.Venus.Data.FileStore.ApiXmlProjectExporter.DoExport(XmlDocument doc)
  at Primavera.Venus.Data.FileStore.ApiXmlProjectExporter.Export(EntityContext anEntityContext, IApiXmlCommitOptions anExportConfig, String FileName)
  at Primavera.Mercury.CommandLineModule.ExecuteImportExport.DoExport(IMercuryCommandLine commandLine)
  at Prism.Modularity.ModuleInitializer.Initialize(ModuleInfo moduleInfo)
  --- End of inner exception stack trace ---
Failed to load type for module CommandLineModule.
Error was: An exception occurred while initializing module 'CommandLineModule'.
  - The exception message was: The given key was not present in the dictionary.
  - The Assembly that the module was trying to be loaded from was:Primavera.Mercury.CommandLineModule, Version=16.1.0.18077, Culture=neutral, PublicKeyToken=null
  Check the InnerException property of the exception for more information. If the exception occurred while creating an object in a DI container, you can exception.GetRootException() to help locate the root cause of the problem.
  
STEPS
-----------------------
The issue can be reproduced at will with the following steps:
1. Log in P6 16.1 SQLite database.
2. Open Project.
3. Select file, Export to MS Project XML format and step through Export wizard.

BUSINESS IMPACT
-----------------------
The issue has the following business impact:
Due to this issue, users cannot Export Project via MS Project XML.

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms