I haven't but haven't had problems using other COM servers from RoseScript.
Is there a particular line where this fails?

>  -----Original Message-----
> From:         Peter Hazlehurst [mailto:[EMAIL PROTECTED]] 
> Sent: Tuesday, March 05, 2002 11:43 AM
> To:   ROSE_FORUM 
> Subject:      Using MSXML dom inside RoseScript
> 
> I know this is pushing the envelope, but has anyone successfully used
> Microsoft's XMLDOM inside roseScript?
> 
> This is my code:
> 
>       Dim bOk As Boolean
>       Dim domXml As String
>       Dim objectStyle As String
>       Dim objectXml As String
>       Dim rootXml As String
>       Dim xhtmlDom As Object
>       Dim xhtmlObject As Object
>       Dim xhtmlRoot As Object
> 
> On Error GoTo localCatch
> 
>       bOk = False
>       
>       Set xhtmlDom = CreateObject("MSXML2.DOMDocument.4.0")   'Instantiate
> object.
> 
>       xhtmlDom.async = false
>       bOk = xhtmlDom.load(fileName)
>       If bOk = True Then
>               domXml = "!!" + xhtmlDom.xml + "!!"
> 
>               MsgBox domXml
> 
>               xhtmlRoot = xhtmlDom.documentElement
>               If xhtmlRoot Is Not Nothing Then
>                       rootXml = xhtmlRoot.xml
>                       Set xhtmlObject = xhtmlRoot.selectSingleNode("//" +
> xhtmlObjectId)
>               End If
> 
>               Set xhtmlObject = xhtmlDom.selectSingleNode("id=" +
> xhtmlObjectId)
> 
>               objectXml = xhtmlObject.xml
>               objectStyle = xhtmlObject.getAttribute("style")
> 
>       End If
> 
>       Set xhtmlDom = Nothing
>       Set xhtmlObject = Nothing
> 
>       reverseObjectProperties = 1 
> 
> Exit Function
> localCatch:
>       Dim sErr As String
> 
>       sErr = "Error #: " + LTrim(Str(Err.Number)) + NL
>       sErr = sErr + "Error Desc: " +  Err.Description + NL
> 
>       MsgBox sErr
>       RoseApp.WriteErrorLog sErr
>       Set xhtmlDom = Nothing
>       Set xhtmlObject = Nothing
> End Function
> 
> And it seems to choke pretty consistently.... Any ideas?
> 
> Thx
> 
> P
> 
> ________________________
> Peter Hazlehurst
> Chief Technology Officer
> Mercari Technologies
> 
> http:  <www.mercaritech.com>
> w:  703.294.6727 x367
> c:   703.597.1750
> f:    703.294.6516
> efax: 801.457.9458  (PrivateLine)
> 
************************************************************************
* Rose Forum is a public venue for ideas and discussions.
* For technical support, visit http://www.rational.com/support
*
* Post or Reply to: [EMAIL PROTECTED]
* Subscription Requests: [EMAIL PROTECTED]
* Archive of messages:
*    http://www.rational.com/support/usergroups/rose/rose_forum.jsp
* Other Requests: [EMAIL PROTECTED]
*
* To unsubscribe from the list, please send email
*    To: [EMAIL PROTECTED]
*    Subject: <BLANK>
*    Body: unsubscribe rose_forum
*************************************************************************

Reply via email to