ømi
ømi

Reputation: 521

MS Project Export as CSV not generating non english language data

I have been following below link to save MS Project file as CSV

https://support.microsoft.com/en-us/office/export-or-import-data-to-another-file-format-6e6e581f-a580-4f04-aa87-9b6552143d9c#:~:text=Choose%20File%20%3E%20Save%20As.%20Choose%20Browse.%20In,a%20name%20for%20the%20exported%20file.%20Choose%20Save

using Existing Task Export Map to save as CSV

Issue i am facing is after generating CSV, non English data is getting corrupted, showing as "????????" in the CSV

enter image description here

CSV File generated is getting saved as ANSI encoding, there is no way to change it to UTF 8 in Export Wizard

these are all steps can be done Mannully on MS Project I also have MSPPlugin written in DotNet which does same exact steps programmatically have used below APIs to perform the same

https://learn.microsoft.com/en-us/office/vba/api/project.application.mapedit

https://learn.microsoft.com/en-us/office/vba/api/project.application.filesaveas

Dim g_projAppObj As MSProject.Application

g_projAppObj.MapEdit(Name:="Task Export Map", Create:=True, OverwriteExisting:=True,
    DataCategory:=MSProject.PjDataCategories.pjMapTasks,
    FieldName:="Task_UID", ExternalFieldName:="Task_UID",
    CategoryEnabled:=True, TableName:="Task Export Map", ImportMethod:=0, HeaderRow:=True,
    AssignmentData:=False, TextDelimiter:=",",
    TextFileOrigin:=MSProject.PjTextFileOrigin.pjTextOriginUnicode,
    UseHtmlTemplate:=False, IncludeImage:=False)

g_projAppObj.FileSaveAs(Name:=w_FileName, Format:=MSProject.PjFileFormat.pjCSV, Map:="Task Export Map")

getting same output as shown in screenshot

Note: I have MS Project 2019 Standard

Upvotes: 2

Views: 78

Answers (0)

Related Questions