Create Complete Project XML (1 Viewer)

kc1

Registered User.
Local time
Yesterday, 16:31
Joined
Sep 22, 2008
Messages
23
Hi

I am having issues with creating a MS Project XML from Access.

I have created an XML file from MS Project and imported into Access, this created the required tables.

Now, when I create the Project XML from Access that I want to import back into MS Project, the XML is created fine but when I import it into Project it is totally blank.

Here is my code that creates the XML file that includes all Access tables.

'Private Sub btnExportXML_Click()
Dim objOtherTbls As AdditionalData


sImportTables = "tbl_MSPImportTableList"

Set objOtherTbls = Application.CreateAdditionalData

rs.Open sImportTables, CurrentProject.Connection, adOpenKeyset, adLockOptimistic

With rs

Do Until .EOF

sTableName = rs.Fields(1)

'Identify the tables or querys to export
objOtherTbls.Add sTableName

.MoveNext

Loop

End With

rs.Close

'Here is where the export takes place
'Application.ExportXML ObjectType:=acExportTable, DataSource:="Assignment", DataTarget:="D:\DB\XMLExportLinks.xml", acEmbedSchema, AdditionalData:=objOtherTbls
Application.ExportXML acExportTable, "Assignment", "D:\DB\XMLExportLinks.xml", "D:\DB\XMLExportLinksSchema.xml", , , acUTF8, acExcludePrimaryKeyAndIndexes, , objOtherTbls

MsgBox "Export operation completed successfully."'

Really stuck on this. I need to import the exact same structure as I exported from MS Project originally.
 

Users who are viewing this thread

Top Bottom