All I need to do is parse data and copy it into variables.
We are moving data from a custom C# ap into Word, using XML copied to the
clipboard. I'm working on the VBA code, not the C# ap. Having a hard time
getting started. I found this
http://msdn2.microsoft.com/en-us/library/aa163921(office.10).aspx
Unfortunately, the code doesn't work in Word 2007. Typos it seems. :(
Any help about where to start would be appreciated.
I did set a reference to MSXML, but still get errors.
Bit hard to diagnose, since you don't say what's actually going wrong or
what errors you get. MSXML certainly works in general. But you're also right
about the typos in the MS example. It seems to have lost many of (but not
all) of its spaces. Lines like
ForEachoCountry InoRoot.childNodes
should obviously be
For Each oCountry In oRoot.childNodes
etc.
> All I need to do is parse data and copy it into variables.
>
[quoted text clipped - 6 lines]
> Any help about where to start would be appreciated.
> I did set a reference to MSXML, but still get errors.
DavidF - 02 Mar 2007 06:48 GMT
Found the main problem:
This won't compile:
Dim oTest As MSXML.DOMDocument
This will compile:
Dim oTest As MSXML2.DOMDocument
Using later versions of MSXML cause this problem.
Stumbled onto it searching the internet.
Thanks,

Signature
df
> Bit hard to diagnose, since you don't say what's actually going wrong or
> what errors you get. MSXML certainly works in general. But you're also
[quoted text clipped - 19 lines]
>> Any help about where to start would be appreciated.
>> I did set a reference to MSXML, but still get errors.