Results 1 to 10 of 10

Thread: [RESOLVED] Remove A Node from an XML document

Hybrid View

  1. #1

    Thread Starter
    No place like 127.0.0.1 eyeRmonkey's Avatar
    Join Date
    Jul 2005
    Location
    Blissful Oblivion
    Posts
    2,306

    Re: Remove A Node from an XML document

    Don't worry about it. I just did it using Replace$() like you guys mentioned. I was just hoping there would be an easy way to do it using the proper methods. Thanks anyway.
    Visual Studio 2005 Professional Edition (.NET Framework 2.0)
    ~ VB .NET Links: Visual Basic 6 to .NET Function Equivalents (Thread) | Refactor! (White Paper) | Easy Control for Wizard Forms | Making A Proper UI For WinForms | Graphics & GDI+ Tutorial | Websites For Free Icons
    ~ QUOTE: Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning. -Rich Cook

    ~ eyeRmonkey.com

  2. #2
    Lively Member
    Join Date
    Jul 2008
    Posts
    73

    Re: [RESOLVED] Remove A Node from an XML document

    i am aslo facing the same issue
    a xml file is created thr' code using vb6.0 & parsed for validation using sax parser
    when paarsing due to line formating
    <?xml version="1.0" encoding="utf-8" standalone="yes" ?> gets appended to the existing data at the start of the file ie the first line
    is there any way that it culd be deleted programatically

    i dont need the above line as per the format specified by the client

    i tried using

    Dim xmldom1 As MSXML2.DOMDocument40
    xmldom1.Load FileName

    Dim toRemove As String
    toRemove = "UTF-16"
    Set nodeTemp = xmldom1.selectSingleNode("xml version/encoding[@standalone = '" + toRemove + "']")
    nodeInvoiceItems.parentNode.removeChild (nodeTemp)

    wit reference to the links i trried to delete but not getting

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width