Load XMLDMO into recordset for PJGrid.ocx

V

Ves

I'm working with the PJGrid control. It can be bound to a ADO recordset. I
want to load a Project XML file into the recordset and then bind the grid to
the recordset. The point is to display project information in the grid,
just like a normal GANTT chart.

Microsoft has some examples that are suppose to show you how to do a part of
this; namely, load the file into a DOMDocument and then open it into a
recordset:

Here's a snippet that loads the xml file into a DOMDocument
'Load the XML string parameter into a DOM document
Set xmlDom = CreateObject("MSXML2.DOMDocument")
xmlDom.async = False
xmlDom.load xml

from there the records set can be loaded as follows:

Dim oRecordset As ADODB.Recordset
Set oRecordset = New ADODB.Recordset
oRecordset.Open xmlDom

I've tried the equivalent of this in VBA (As a macro in Microsoft Project),
in JavaScript inserted into a LoadWebBrowser custom script, and in Visual
Studio in C#. Regardless of where I try this it always fails at the Open.

Has anyone out there done anything like this? If this isn't the way to do
it, then how do I get a Project xml file into a recordset? Thanks for any
help.

Ves
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top