Public Function EditXml(strPath As String) As Integer ''Edicion de un archivo xml. Dim document As New XmlDocument Dim element As New XmlElement Dim node As XmlNode Dim strSave As String Dim int As Integer Dim str As String Dim stx As New String[] strSave = File.Dir(strPath) &/ File.BaseName(strPath) & "-prod." & File.Ext(strPath) document.Open(strPath) For Each element In document.GetElementsByTagName("text", gb.IgnoreCase) For Each node In element.Attributes Select node.Name Case "id" 'If node.Value = "dvariety" element.Value = "variedad" For Each node In element.Attributes Select node.Name Case "style" stx = Split(node.Value, ";") For int = 0 To stx.max Select Split(stx[int], ":")[0] Case "fill" stx[int] = "fill:#FF0000" End Select Next node.Value = stx.Join(";") End Select Next 'Endif End Select Next Next document.Save(strSave) Return 1 End