'' ------------------------------------------------------------------------------
''  <auto-generated>
''    Generated by Xsd2Code++. Version 6.0.0.0. www.xsd2code.com
''    {"TargetFramework":"Net48","NameSpace":"CC305A_v10_0","Language":"VisualBasic","Properties":{},"XmlAttribute":{"Enabled":true},"ClassParams":{},"Serialization":{"ShouldSerialize":{},"AdditionalSerializers":{},"XmlSerializerEvent":{},"XmlOutput":{"Formating":true},"JsonOutput":{},"Enabled":true},"Miscellaneous":{}}
''  </auto-generated>
'' ------------------------------------------------------------------------------
#Disable Warning
Imports System
Imports System.Diagnostics
Imports System.Xml.Serialization
Imports System.Runtime.Serialization
Imports System.Collections
Imports System.Xml.Schema
Imports System.ComponentModel
Imports System.Xml
Imports System.IO
Imports System.Text
Imports System.Collections.Generic

Namespace CC305A_v10_0

    <System.CodeDom.Compiler.GeneratedCode("System.Xml", "4.8.9037.0"),
     System.Serializable,
     DebuggerStepThrough,
     DesignerCategoryAttribute("code"),
     XmlType([Namespace]:="http://ics.dgtaxud.ec/CC305A"),
     XmlRoot("CC305A", [Namespace]:="http://ics.dgtaxud.ec/CC305A", IsNullable:=False)>
    Partial Public Class CC305AType

#Region "Private fields"
        Private _mesSenMES3 As String

        Private _mesRecMES6 As String

        Private _datOfPreMES9 As String

        Private _timOfPreMES10 As String

        Private _priMES15 As String

        Private _tesIndMES18 As Flag

        Private _mesIdeMES19 As String

        Private _mesTypMES20 As MessageTypes

        Private _corIdeMES25 As String

        Private _hEAHEA As HEAHEAType

        Private _fUNERRER1 As List(Of FUNERRER1Type)

        Private _tRAREP As TRAREPType

        Private _pERLODSUMDEC As PERLODSUMDECType

        Private _cUSOFFFENT730 As CUSOFFFENT730Type

        Private Shared _serializerXml As XmlSerializer
#End Region

        Public Sub New()
            MyBase.New
            Me._cUSOFFFENT730 = New CUSOFFFENT730Type()
            Me._pERLODSUMDEC = New PERLODSUMDECType()
            Me._tRAREP = New TRAREPType()
            Me._fUNERRER1 = New List(Of FUNERRER1Type)()
            Me._hEAHEA = New HEAHEAType()
        End Sub

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property MesSenMES3() As String
            Get
                Return Me._mesSenMES3
            End Get
            Set
                Me._mesSenMES3 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property MesRecMES6() As String
            Get
                Return Me._mesRecMES6
            End Get
            Set
                Me._mesRecMES6 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property DatOfPreMES9() As String
            Get
                Return Me._datOfPreMES9
            End Get
            Set
                Me._datOfPreMES9 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property TimOfPreMES10() As String
            Get
                Return Me._timOfPreMES10
            End Get
            Set
                Me._timOfPreMES10 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property PriMES15() As String
            Get
                Return Me._priMES15
            End Get
            Set
                Me._priMES15 = Value
            End Set
        End Property

        <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Unqualified)>
        Public Property TesIndMES18() As Flag
            Get
                Return Me._tesIndMES18
            End Get
            Set
                Me._tesIndMES18 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property MesIdeMES19() As String
            Get
                Return Me._mesIdeMES19
            End Get
            Set
                Me._mesIdeMES19 = Value
            End Set
        End Property

        <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Unqualified)>
        Public Property MesTypMES20() As MessageTypes
            Get
                Return Me._mesTypMES20
            End Get
            Set
                Me._mesTypMES20 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property CorIdeMES25() As String
            Get
                Return Me._corIdeMES25
            End Get
            Set
                Me._corIdeMES25 = Value
            End Set
        End Property

        <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Unqualified)>
        Public Property HEAHEA() As HEAHEAType
            Get
                Return Me._hEAHEA
            End Get
            Set
                Me._hEAHEA = Value
            End Set
        End Property

        <XmlElement("FUNERRER1", Form:=System.Xml.Schema.XmlSchemaForm.Unqualified)>
        Public Property FUNERRER1() As List(Of FUNERRER1Type)
            Get
                Return Me._fUNERRER1
            End Get
            Set
                Me._fUNERRER1 = Value
            End Set
        End Property

        <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Unqualified)>
        Public Property TRAREP() As TRAREPType
            Get
                Return Me._tRAREP
            End Get
            Set
                Me._tRAREP = Value
            End Set
        End Property

        <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Unqualified)>
        Public Property PERLODSUMDEC() As PERLODSUMDECType
            Get
                Return Me._pERLODSUMDEC
            End Get
            Set
                Me._pERLODSUMDEC = Value
            End Set
        End Property

        <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Unqualified)>
        Public Property CUSOFFFENT730() As CUSOFFFENT730Type
            Get
                Return Me._cUSOFFFENT730
            End Get
            Set
                Me._cUSOFFFENT730 = Value
            End Set
        End Property

        Private Shared ReadOnly Property SerializerXml() As XmlSerializer
            Get
                If (_serializerXml Is Nothing) Then
                    _serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(CC305AType))
                End If
                Return _serializerXml
            End Get
        End Property

#Region "Serialize/Deserialize"
        ''' <summary>
        ''' Serialize CC305AType object
        ''' </summary>
        ''' <returns>XML value</returns>
        Public Overridable Function Serialize() As String
            Dim streamReader As StreamReader = Nothing
            Dim memoryStream As MemoryStream = Nothing
            Try
                memoryStream = New MemoryStream()
                Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
                xmlWriterSettings.Indent = True
                xmlWriterSettings.IndentChars = "  "
                Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
                SerializerXml.Serialize(xmlWriter, Me)
                memoryStream.Seek(0, SeekOrigin.Begin)
                streamReader = New StreamReader(memoryStream)
                Return streamReader.ReadToEnd
            Finally
                If (Not (streamReader) Is Nothing) Then
                    streamReader.Dispose()
                End If
                If (Not (memoryStream) Is Nothing) Then
                    memoryStream.Dispose()
                End If
            End Try
        End Function

        ''' <summary>
        ''' Deserializes CC305AType object
        ''' </summary>
        ''' <param name="input">string to deserialize</param>
        ''' <param name="obj">Output CC305AType object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CC305AType, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, CC305AType)
            Try
                obj = Deserialize(input)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CC305AType) As Boolean
            Dim exception As System.Exception = Nothing
            Return Deserialize(input, obj, exception)
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String) As CC305AType
            Dim stringReader As StringReader = Nothing
            Try
                stringReader = New StringReader(input)
                Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), CC305AType)
            Finally
                If (Not (stringReader) Is Nothing) Then
                    stringReader.Dispose()
                End If
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal s As Stream) As CC305AType
            Return CType(SerializerXml.Deserialize(s), CC305AType)
        End Function
#End Region

        ''' <summary>
        ''' Serializes current CC305AType object into file
        ''' </summary>
        ''' <param name="fileName">full path of outupt xml file</param>
        ''' <param name="exception">output Exception value if failed</param>
        ''' <returns>true if can serialize and save into file; otherwise, false</returns>
        Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            Try
                SaveToFile(fileName)
                Return True
            Catch e As System.Exception
                exception = e
                Return False
            End Try
        End Function

        Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
            Dim streamWriter As StreamWriter = Nothing
            Try
                Dim dataString As String = Serialize()
                Dim outputFile As FileInfo = New FileInfo(fileName)
                streamWriter = outputFile.CreateText
                streamWriter.WriteLine(dataString)
                streamWriter.Close()
            Finally
                If (Not (streamWriter) Is Nothing) Then
                    streamWriter.Dispose()
                End If
            End Try
        End Sub

        ''' <summary>
        ''' Deserializes xml markup from file into an CC305AType object
        ''' </summary>
        ''' <param name="fileName">File to load and deserialize</param>
        ''' <param name="obj">Output CC305AType object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CC305AType, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, CC305AType)
            Try
                obj = LoadFromFile(fileName)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CC305AType) As Boolean
            Dim exception As System.Exception = Nothing
            Return LoadFromFile(fileName, obj, exception)
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As CC305AType
            Dim file As FileStream = Nothing
            Dim sr As StreamReader = Nothing
            Try
                file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
                sr = New StreamReader(file)
                Dim dataString As String = sr.ReadToEnd
                sr.Close()
                file.Close()
                Return Deserialize(dataString)
            Finally
                If (Not (file) Is Nothing) Then
                    file.Dispose()
                End If
                If (Not (sr) Is Nothing) Then
                    sr.Dispose()
                End If
            End Try
        End Function
    End Class

    <System.CodeDom.Compiler.GeneratedCode("System.Xml", "4.8.9037.0"),
     System.Serializable,
     XmlType([Namespace]:="http://ics.dgtaxud.ec/tcl")>
    Public Enum Flag

        <XmlEnum("0")>
        Item0

        <XmlEnum("1")>
        Item1
    End Enum

    <System.CodeDom.Compiler.GeneratedCode("System.Xml", "4.8.9037.0"),
     System.Serializable,
     XmlType([Namespace]:="http://ics.dgtaxud.ec/tcl")>
    Public Enum MessageTypes

        CC304A

        CC305A

        CC313A

        CC315A

        CC316A

        CC323A

        CC324A

        CC325A

        CC328A

        CC351A

        CD030C

        CD031C

        CD032C

        CD070B

        CD071B

        CD301A

        CD302A

        CD303A

        CD319A

        CD411C

        CD412C

        CD906B

        CD912B

        CD913B

        CD914B

        CD916B

        CD917B

        CD931C

        CD932C

        CD971B
    End Enum

    <System.CodeDom.Compiler.GeneratedCode("System.Xml", "4.8.9037.0"),
     System.Serializable,
     DebuggerStepThrough,
     DesignerCategoryAttribute("code"),
     XmlType([Namespace]:="http://ics.dgtaxud.ec/CC305A")>
    Partial Public Class HEAHEAType

#Region "Private fields"
        Private _docNumHEA5 As String

        Private _ameRejMotCodHEA604 As String

        Private _ameRejMotTexHEA605 As String

        Private _ameRejMotTexHEA605LNG As String

        Private _datTimAmeHEA113 As String

        Private _ameRejDatTimHEA112 As String

        Private Shared _serializerXml As XmlSerializer
#End Region

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property DocNumHEA5() As String
            Get
                Return Me._docNumHEA5
            End Get
            Set
                Me._docNumHEA5 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property AmeRejMotCodHEA604() As String
            Get
                Return Me._ameRejMotCodHEA604
            End Get
            Set
                Me._ameRejMotCodHEA604 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property AmeRejMotTexHEA605() As String
            Get
                Return Me._ameRejMotTexHEA605
            End Get
            Set
                Me._ameRejMotTexHEA605 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property AmeRejMotTexHEA605LNG() As String
            Get
                Return Me._ameRejMotTexHEA605LNG
            End Get
            Set
                Me._ameRejMotTexHEA605LNG = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property DatTimAmeHEA113() As String
            Get
                Return Me._datTimAmeHEA113
            End Get
            Set
                Me._datTimAmeHEA113 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property AmeRejDatTimHEA112() As String
            Get
                Return Me._ameRejDatTimHEA112
            End Get
            Set
                Me._ameRejDatTimHEA112 = Value
            End Set
        End Property

        Private Shared ReadOnly Property SerializerXml() As XmlSerializer
            Get
                If (_serializerXml Is Nothing) Then
                    _serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(HEAHEAType))
                End If
                Return _serializerXml
            End Get
        End Property

#Region "Serialize/Deserialize"
        ''' <summary>
        ''' Serialize HEAHEAType object
        ''' </summary>
        ''' <returns>XML value</returns>
        Public Overridable Function Serialize() As String
            Dim streamReader As StreamReader = Nothing
            Dim memoryStream As MemoryStream = Nothing
            Try
                memoryStream = New MemoryStream()
                Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
                xmlWriterSettings.Indent = True
                xmlWriterSettings.IndentChars = "  "
                Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
                SerializerXml.Serialize(xmlWriter, Me)
                memoryStream.Seek(0, SeekOrigin.Begin)
                streamReader = New StreamReader(memoryStream)
                Return streamReader.ReadToEnd
            Finally
                If (Not (streamReader) Is Nothing) Then
                    streamReader.Dispose()
                End If
                If (Not (memoryStream) Is Nothing) Then
                    memoryStream.Dispose()
                End If
            End Try
        End Function

        ''' <summary>
        ''' Deserializes HEAHEAType object
        ''' </summary>
        ''' <param name="input">string to deserialize</param>
        ''' <param name="obj">Output HEAHEAType object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As HEAHEAType, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, HEAHEAType)
            Try
                obj = Deserialize(input)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As HEAHEAType) As Boolean
            Dim exception As System.Exception = Nothing
            Return Deserialize(input, obj, exception)
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String) As HEAHEAType
            Dim stringReader As StringReader = Nothing
            Try
                stringReader = New StringReader(input)
                Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), HEAHEAType)
            Finally
                If (Not (stringReader) Is Nothing) Then
                    stringReader.Dispose()
                End If
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal s As Stream) As HEAHEAType
            Return CType(SerializerXml.Deserialize(s), HEAHEAType)
        End Function
#End Region

        ''' <summary>
        ''' Serializes current HEAHEAType object into file
        ''' </summary>
        ''' <param name="fileName">full path of outupt xml file</param>
        ''' <param name="exception">output Exception value if failed</param>
        ''' <returns>true if can serialize and save into file; otherwise, false</returns>
        Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            Try
                SaveToFile(fileName)
                Return True
            Catch e As System.Exception
                exception = e
                Return False
            End Try
        End Function

        Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
            Dim streamWriter As StreamWriter = Nothing
            Try
                Dim dataString As String = Serialize()
                Dim outputFile As FileInfo = New FileInfo(fileName)
                streamWriter = outputFile.CreateText
                streamWriter.WriteLine(dataString)
                streamWriter.Close()
            Finally
                If (Not (streamWriter) Is Nothing) Then
                    streamWriter.Dispose()
                End If
            End Try
        End Sub

        ''' <summary>
        ''' Deserializes xml markup from file into an HEAHEAType object
        ''' </summary>
        ''' <param name="fileName">File to load and deserialize</param>
        ''' <param name="obj">Output HEAHEAType object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As HEAHEAType, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, HEAHEAType)
            Try
                obj = LoadFromFile(fileName)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As HEAHEAType) As Boolean
            Dim exception As System.Exception = Nothing
            Return LoadFromFile(fileName, obj, exception)
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As HEAHEAType
            Dim file As FileStream = Nothing
            Dim sr As StreamReader = Nothing
            Try
                file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
                sr = New StreamReader(file)
                Dim dataString As String = sr.ReadToEnd
                sr.Close()
                file.Close()
                Return Deserialize(dataString)
            Finally
                If (Not (file) Is Nothing) Then
                    file.Dispose()
                End If
                If (Not (sr) Is Nothing) Then
                    sr.Dispose()
                End If
            End Try
        End Function
    End Class

    <System.CodeDom.Compiler.GeneratedCode("System.Xml", "4.8.9037.0"),
     System.Serializable,
     DebuggerStepThrough,
     DesignerCategoryAttribute("code"),
     XmlType([Namespace]:="http://ics.dgtaxud.ec/CC305A")>
    Partial Public Class CUSOFFFENT730Type

#Region "Private fields"
        Private _refNumCUSOFFFENT731 As String

        Private Shared _serializerXml As XmlSerializer
#End Region

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property RefNumCUSOFFFENT731() As String
            Get
                Return Me._refNumCUSOFFFENT731
            End Get
            Set
                Me._refNumCUSOFFFENT731 = Value
            End Set
        End Property

        Private Shared ReadOnly Property SerializerXml() As XmlSerializer
            Get
                If (_serializerXml Is Nothing) Then
                    _serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(CUSOFFFENT730Type))
                End If
                Return _serializerXml
            End Get
        End Property

#Region "Serialize/Deserialize"
        ''' <summary>
        ''' Serialize CUSOFFFENT730Type object
        ''' </summary>
        ''' <returns>XML value</returns>
        Public Overridable Function Serialize() As String
            Dim streamReader As StreamReader = Nothing
            Dim memoryStream As MemoryStream = Nothing
            Try
                memoryStream = New MemoryStream()
                Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
                xmlWriterSettings.Indent = True
                xmlWriterSettings.IndentChars = "  "
                Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
                SerializerXml.Serialize(xmlWriter, Me)
                memoryStream.Seek(0, SeekOrigin.Begin)
                streamReader = New StreamReader(memoryStream)
                Return streamReader.ReadToEnd
            Finally
                If (Not (streamReader) Is Nothing) Then
                    streamReader.Dispose()
                End If
                If (Not (memoryStream) Is Nothing) Then
                    memoryStream.Dispose()
                End If
            End Try
        End Function

        ''' <summary>
        ''' Deserializes CUSOFFFENT730Type object
        ''' </summary>
        ''' <param name="input">string to deserialize</param>
        ''' <param name="obj">Output CUSOFFFENT730Type object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CUSOFFFENT730Type, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, CUSOFFFENT730Type)
            Try
                obj = Deserialize(input)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As CUSOFFFENT730Type) As Boolean
            Dim exception As System.Exception = Nothing
            Return Deserialize(input, obj, exception)
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String) As CUSOFFFENT730Type
            Dim stringReader As StringReader = Nothing
            Try
                stringReader = New StringReader(input)
                Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), CUSOFFFENT730Type)
            Finally
                If (Not (stringReader) Is Nothing) Then
                    stringReader.Dispose()
                End If
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal s As Stream) As CUSOFFFENT730Type
            Return CType(SerializerXml.Deserialize(s), CUSOFFFENT730Type)
        End Function
#End Region

        ''' <summary>
        ''' Serializes current CUSOFFFENT730Type object into file
        ''' </summary>
        ''' <param name="fileName">full path of outupt xml file</param>
        ''' <param name="exception">output Exception value if failed</param>
        ''' <returns>true if can serialize and save into file; otherwise, false</returns>
        Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            Try
                SaveToFile(fileName)
                Return True
            Catch e As System.Exception
                exception = e
                Return False
            End Try
        End Function

        Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
            Dim streamWriter As StreamWriter = Nothing
            Try
                Dim dataString As String = Serialize()
                Dim outputFile As FileInfo = New FileInfo(fileName)
                streamWriter = outputFile.CreateText
                streamWriter.WriteLine(dataString)
                streamWriter.Close()
            Finally
                If (Not (streamWriter) Is Nothing) Then
                    streamWriter.Dispose()
                End If
            End Try
        End Sub

        ''' <summary>
        ''' Deserializes xml markup from file into an CUSOFFFENT730Type object
        ''' </summary>
        ''' <param name="fileName">File to load and deserialize</param>
        ''' <param name="obj">Output CUSOFFFENT730Type object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CUSOFFFENT730Type, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, CUSOFFFENT730Type)
            Try
                obj = LoadFromFile(fileName)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As CUSOFFFENT730Type) As Boolean
            Dim exception As System.Exception = Nothing
            Return LoadFromFile(fileName, obj, exception)
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As CUSOFFFENT730Type
            Dim file As FileStream = Nothing
            Dim sr As StreamReader = Nothing
            Try
                file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
                sr = New StreamReader(file)
                Dim dataString As String = sr.ReadToEnd
                sr.Close()
                file.Close()
                Return Deserialize(dataString)
            Finally
                If (Not (file) Is Nothing) Then
                    file.Dispose()
                End If
                If (Not (sr) Is Nothing) Then
                    sr.Dispose()
                End If
            End Try
        End Function
    End Class

    <System.CodeDom.Compiler.GeneratedCode("System.Xml", "4.8.9037.0"),
     System.Serializable,
     DebuggerStepThrough,
     DesignerCategoryAttribute("code"),
     XmlType([Namespace]:="http://ics.dgtaxud.ec/CC305A")>
    Partial Public Class PERLODSUMDECType

#Region "Private fields"
        Private _namPLD1 As String

        Private _strAndNumPLD1 As String

        Private _posCodPLD1 As String

        Private _citPLD1 As String

        Private _couCodPLD1 As String

        Private _pERLODSUMDECLNG As String

        Private _tINPLD1 As String

        Private Shared _serializerXml As XmlSerializer
#End Region

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property NamPLD1() As String
            Get
                Return Me._namPLD1
            End Get
            Set
                Me._namPLD1 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property StrAndNumPLD1() As String
            Get
                Return Me._strAndNumPLD1
            End Get
            Set
                Me._strAndNumPLD1 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property PosCodPLD1() As String
            Get
                Return Me._posCodPLD1
            End Get
            Set
                Me._posCodPLD1 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property CitPLD1() As String
            Get
                Return Me._citPLD1
            End Get
            Set
                Me._citPLD1 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property CouCodPLD1() As String
            Get
                Return Me._couCodPLD1
            End Get
            Set
                Me._couCodPLD1 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property PERLODSUMDECLNG() As String
            Get
                Return Me._pERLODSUMDECLNG
            End Get
            Set
                Me._pERLODSUMDECLNG = Value
            End Set
        End Property

        <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Unqualified)>
        Public Property TINPLD1() As String
            Get
                Return Me._tINPLD1
            End Get
            Set
                Me._tINPLD1 = Value
            End Set
        End Property

        Private Shared ReadOnly Property SerializerXml() As XmlSerializer
            Get
                If (_serializerXml Is Nothing) Then
                    _serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(PERLODSUMDECType))
                End If
                Return _serializerXml
            End Get
        End Property

#Region "Serialize/Deserialize"
        ''' <summary>
        ''' Serialize PERLODSUMDECType object
        ''' </summary>
        ''' <returns>XML value</returns>
        Public Overridable Function Serialize() As String
            Dim streamReader As StreamReader = Nothing
            Dim memoryStream As MemoryStream = Nothing
            Try
                memoryStream = New MemoryStream()
                Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
                xmlWriterSettings.Indent = True
                xmlWriterSettings.IndentChars = "  "
                Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
                SerializerXml.Serialize(xmlWriter, Me)
                memoryStream.Seek(0, SeekOrigin.Begin)
                streamReader = New StreamReader(memoryStream)
                Return streamReader.ReadToEnd
            Finally
                If (Not (streamReader) Is Nothing) Then
                    streamReader.Dispose()
                End If
                If (Not (memoryStream) Is Nothing) Then
                    memoryStream.Dispose()
                End If
            End Try
        End Function

        ''' <summary>
        ''' Deserializes PERLODSUMDECType object
        ''' </summary>
        ''' <param name="input">string to deserialize</param>
        ''' <param name="obj">Output PERLODSUMDECType object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As PERLODSUMDECType, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, PERLODSUMDECType)
            Try
                obj = Deserialize(input)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As PERLODSUMDECType) As Boolean
            Dim exception As System.Exception = Nothing
            Return Deserialize(input, obj, exception)
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String) As PERLODSUMDECType
            Dim stringReader As StringReader = Nothing
            Try
                stringReader = New StringReader(input)
                Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), PERLODSUMDECType)
            Finally
                If (Not (stringReader) Is Nothing) Then
                    stringReader.Dispose()
                End If
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal s As Stream) As PERLODSUMDECType
            Return CType(SerializerXml.Deserialize(s), PERLODSUMDECType)
        End Function
#End Region

        ''' <summary>
        ''' Serializes current PERLODSUMDECType object into file
        ''' </summary>
        ''' <param name="fileName">full path of outupt xml file</param>
        ''' <param name="exception">output Exception value if failed</param>
        ''' <returns>true if can serialize and save into file; otherwise, false</returns>
        Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            Try
                SaveToFile(fileName)
                Return True
            Catch e As System.Exception
                exception = e
                Return False
            End Try
        End Function

        Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
            Dim streamWriter As StreamWriter = Nothing
            Try
                Dim dataString As String = Serialize()
                Dim outputFile As FileInfo = New FileInfo(fileName)
                streamWriter = outputFile.CreateText
                streamWriter.WriteLine(dataString)
                streamWriter.Close()
            Finally
                If (Not (streamWriter) Is Nothing) Then
                    streamWriter.Dispose()
                End If
            End Try
        End Sub

        ''' <summary>
        ''' Deserializes xml markup from file into an PERLODSUMDECType object
        ''' </summary>
        ''' <param name="fileName">File to load and deserialize</param>
        ''' <param name="obj">Output PERLODSUMDECType object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As PERLODSUMDECType, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, PERLODSUMDECType)
            Try
                obj = LoadFromFile(fileName)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As PERLODSUMDECType) As Boolean
            Dim exception As System.Exception = Nothing
            Return LoadFromFile(fileName, obj, exception)
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As PERLODSUMDECType
            Dim file As FileStream = Nothing
            Dim sr As StreamReader = Nothing
            Try
                file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
                sr = New StreamReader(file)
                Dim dataString As String = sr.ReadToEnd
                sr.Close()
                file.Close()
                Return Deserialize(dataString)
            Finally
                If (Not (file) Is Nothing) Then
                    file.Dispose()
                End If
                If (Not (sr) Is Nothing) Then
                    sr.Dispose()
                End If
            End Try
        End Function
    End Class

    <System.CodeDom.Compiler.GeneratedCode("System.Xml", "4.8.9037.0"),
     System.Serializable,
     DebuggerStepThrough,
     DesignerCategoryAttribute("code"),
     XmlType([Namespace]:="http://ics.dgtaxud.ec/CC305A")>
    Partial Public Class TRAREPType

#Region "Private fields"
        Private _namTRE1 As String

        Private _strAndNumTRE1 As String

        Private _posCodTRE1 As String

        Private _citTRE1 As String

        Private _couCodTRE1 As String

        Private _tRAREPLNG As String

        Private _tINTRE1 As String

        Private Shared _serializerXml As XmlSerializer
#End Region

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property NamTRE1() As String
            Get
                Return Me._namTRE1
            End Get
            Set
                Me._namTRE1 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property StrAndNumTRE1() As String
            Get
                Return Me._strAndNumTRE1
            End Get
            Set
                Me._strAndNumTRE1 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property PosCodTRE1() As String
            Get
                Return Me._posCodTRE1
            End Get
            Set
                Me._posCodTRE1 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property CitTRE1() As String
            Get
                Return Me._citTRE1
            End Get
            Set
                Me._citTRE1 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property CouCodTRE1() As String
            Get
                Return Me._couCodTRE1
            End Get
            Set
                Me._couCodTRE1 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property TRAREPLNG() As String
            Get
                Return Me._tRAREPLNG
            End Get
            Set
                Me._tRAREPLNG = Value
            End Set
        End Property

        <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Unqualified)>
        Public Property TINTRE1() As String
            Get
                Return Me._tINTRE1
            End Get
            Set
                Me._tINTRE1 = Value
            End Set
        End Property

        Private Shared ReadOnly Property SerializerXml() As XmlSerializer
            Get
                If (_serializerXml Is Nothing) Then
                    _serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(TRAREPType))
                End If
                Return _serializerXml
            End Get
        End Property

#Region "Serialize/Deserialize"
        ''' <summary>
        ''' Serialize TRAREPType object
        ''' </summary>
        ''' <returns>XML value</returns>
        Public Overridable Function Serialize() As String
            Dim streamReader As StreamReader = Nothing
            Dim memoryStream As MemoryStream = Nothing
            Try
                memoryStream = New MemoryStream()
                Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
                xmlWriterSettings.Indent = True
                xmlWriterSettings.IndentChars = "  "
                Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
                SerializerXml.Serialize(xmlWriter, Me)
                memoryStream.Seek(0, SeekOrigin.Begin)
                streamReader = New StreamReader(memoryStream)
                Return streamReader.ReadToEnd
            Finally
                If (Not (streamReader) Is Nothing) Then
                    streamReader.Dispose()
                End If
                If (Not (memoryStream) Is Nothing) Then
                    memoryStream.Dispose()
                End If
            End Try
        End Function

        ''' <summary>
        ''' Deserializes TRAREPType object
        ''' </summary>
        ''' <param name="input">string to deserialize</param>
        ''' <param name="obj">Output TRAREPType object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As TRAREPType, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, TRAREPType)
            Try
                obj = Deserialize(input)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As TRAREPType) As Boolean
            Dim exception As System.Exception = Nothing
            Return Deserialize(input, obj, exception)
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String) As TRAREPType
            Dim stringReader As StringReader = Nothing
            Try
                stringReader = New StringReader(input)
                Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), TRAREPType)
            Finally
                If (Not (stringReader) Is Nothing) Then
                    stringReader.Dispose()
                End If
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal s As Stream) As TRAREPType
            Return CType(SerializerXml.Deserialize(s), TRAREPType)
        End Function
#End Region

        ''' <summary>
        ''' Serializes current TRAREPType object into file
        ''' </summary>
        ''' <param name="fileName">full path of outupt xml file</param>
        ''' <param name="exception">output Exception value if failed</param>
        ''' <returns>true if can serialize and save into file; otherwise, false</returns>
        Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            Try
                SaveToFile(fileName)
                Return True
            Catch e As System.Exception
                exception = e
                Return False
            End Try
        End Function

        Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
            Dim streamWriter As StreamWriter = Nothing
            Try
                Dim dataString As String = Serialize()
                Dim outputFile As FileInfo = New FileInfo(fileName)
                streamWriter = outputFile.CreateText
                streamWriter.WriteLine(dataString)
                streamWriter.Close()
            Finally
                If (Not (streamWriter) Is Nothing) Then
                    streamWriter.Dispose()
                End If
            End Try
        End Sub

        ''' <summary>
        ''' Deserializes xml markup from file into an TRAREPType object
        ''' </summary>
        ''' <param name="fileName">File to load and deserialize</param>
        ''' <param name="obj">Output TRAREPType object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As TRAREPType, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, TRAREPType)
            Try
                obj = LoadFromFile(fileName)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As TRAREPType) As Boolean
            Dim exception As System.Exception = Nothing
            Return LoadFromFile(fileName, obj, exception)
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As TRAREPType
            Dim file As FileStream = Nothing
            Dim sr As StreamReader = Nothing
            Try
                file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
                sr = New StreamReader(file)
                Dim dataString As String = sr.ReadToEnd
                sr.Close()
                file.Close()
                Return Deserialize(dataString)
            Finally
                If (Not (file) Is Nothing) Then
                    file.Dispose()
                End If
                If (Not (sr) Is Nothing) Then
                    sr.Dispose()
                End If
            End Try
        End Function
    End Class

    <System.CodeDom.Compiler.GeneratedCode("System.Xml", "4.8.9037.0"),
     System.Serializable,
     DebuggerStepThrough,
     DesignerCategoryAttribute("code"),
     XmlType([Namespace]:="http://ics.dgtaxud.ec/CC305A")>
    Partial Public Class FUNERRER1Type

#Region "Private fields"
        Private _errTypER11 As FunctionalErrorCodes

        Private _errPoiER12 As String

        Private _errReaER13 As String

        Private _oriAttValER14 As String

        Private Shared _serializerXml As XmlSerializer
#End Region

        <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Unqualified)>
        Public Property ErrTypER11() As FunctionalErrorCodes
            Get
                Return Me._errTypER11
            End Get
            Set
                Me._errTypER11 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property ErrPoiER12() As String
            Get
                Return Me._errPoiER12
            End Get
            Set
                Me._errPoiER12 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property ErrReaER13() As String
            Get
                Return Me._errReaER13
            End Get
            Set
                Me._errReaER13 = Value
            End Set
        End Property

       <XmlElement(Form:=System.Xml.Schema.XmlSchemaForm.Qualified, DataType:="token")>
        Public Property OriAttValER14() As String
            Get
                Return Me._oriAttValER14
            End Get
            Set
                Me._oriAttValER14 = Value
            End Set
        End Property

        Private Shared ReadOnly Property SerializerXml() As XmlSerializer
            Get
                If (_serializerXml Is Nothing) Then
                    _serializerXml = New XmlSerializerFactory().CreateSerializer(GetType(FUNERRER1Type))
                End If
                Return _serializerXml
            End Get
        End Property

#Region "Serialize/Deserialize"
        ''' <summary>
        ''' Serialize FUNERRER1Type object
        ''' </summary>
        ''' <returns>XML value</returns>
        Public Overridable Function Serialize() As String
            Dim streamReader As StreamReader = Nothing
            Dim memoryStream As MemoryStream = Nothing
            Try
                memoryStream = New MemoryStream()
                Dim xmlWriterSettings As System.Xml.XmlWriterSettings = New System.Xml.XmlWriterSettings()
                xmlWriterSettings.Indent = True
                xmlWriterSettings.IndentChars = "  "
                Dim xmlWriter As System.Xml.XmlWriter = XmlWriter.Create(memoryStream, xmlWriterSettings)
                SerializerXml.Serialize(xmlWriter, Me)
                memoryStream.Seek(0, SeekOrigin.Begin)
                streamReader = New StreamReader(memoryStream)
                Return streamReader.ReadToEnd
            Finally
                If (Not (streamReader) Is Nothing) Then
                    streamReader.Dispose()
                End If
                If (Not (memoryStream) Is Nothing) Then
                    memoryStream.Dispose()
                End If
            End Try
        End Function

        ''' <summary>
        ''' Deserializes FUNERRER1Type object
        ''' </summary>
        ''' <param name="input">string to deserialize</param>
        ''' <param name="obj">Output FUNERRER1Type object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As FUNERRER1Type, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, FUNERRER1Type)
            Try
                obj = Deserialize(input)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String, ByRef obj As FUNERRER1Type) As Boolean
            Dim exception As System.Exception = Nothing
            Return Deserialize(input, obj, exception)
        End Function

        Public Overloads Shared Function Deserialize(ByVal input As String) As FUNERRER1Type
            Dim stringReader As StringReader = Nothing
            Try
                stringReader = New StringReader(input)
                Return CType(SerializerXml.Deserialize(XmlReader.Create(stringReader)), FUNERRER1Type)
            Finally
                If (Not (stringReader) Is Nothing) Then
                    stringReader.Dispose()
                End If
            End Try
        End Function

        Public Overloads Shared Function Deserialize(ByVal s As Stream) As FUNERRER1Type
            Return CType(SerializerXml.Deserialize(s), FUNERRER1Type)
        End Function
#End Region

        ''' <summary>
        ''' Serializes current FUNERRER1Type object into file
        ''' </summary>
        ''' <param name="fileName">full path of outupt xml file</param>
        ''' <param name="exception">output Exception value if failed</param>
        ''' <returns>true if can serialize and save into file; otherwise, false</returns>
        Public Overridable Overloads Function SaveToFile(ByVal fileName As String, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            Try
                SaveToFile(fileName)
                Return True
            Catch e As System.Exception
                exception = e
                Return False
            End Try
        End Function

        Public Overridable Overloads Sub SaveToFile(ByVal fileName As String)
            Dim streamWriter As StreamWriter = Nothing
            Try
                Dim dataString As String = Serialize()
                Dim outputFile As FileInfo = New FileInfo(fileName)
                streamWriter = outputFile.CreateText
                streamWriter.WriteLine(dataString)
                streamWriter.Close()
            Finally
                If (Not (streamWriter) Is Nothing) Then
                    streamWriter.Dispose()
                End If
            End Try
        End Sub

        ''' <summary>
        ''' Deserializes xml markup from file into an FUNERRER1Type object
        ''' </summary>
        ''' <param name="fileName">File to load and deserialize</param>
        ''' <param name="obj">Output FUNERRER1Type object</param>
        ''' <param name="exception">output Exception value if deserialize failed</param>
        ''' <returns>true if this Serializer can deserialize the object; otherwise, false</returns>
        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As FUNERRER1Type, ByRef exception As System.Exception) As Boolean
            exception = Nothing
            obj = CType(Nothing, FUNERRER1Type)
            Try
                obj = LoadFromFile(fileName)
                Return True
            Catch ex As System.Exception
                exception = ex
                Return False
            End Try
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String, ByRef obj As FUNERRER1Type) As Boolean
            Dim exception As System.Exception = Nothing
            Return LoadFromFile(fileName, obj, exception)
        End Function

        Public Overloads Shared Function LoadFromFile(ByVal fileName As String) As FUNERRER1Type
            Dim file As FileStream = Nothing
            Dim sr As StreamReader = Nothing
            Try
                file = New FileStream(fileName, FileMode.Open, FileAccess.Read)
                sr = New StreamReader(file)
                Dim dataString As String = sr.ReadToEnd
                sr.Close()
                file.Close()
                Return Deserialize(dataString)
            Finally
                If (Not (file) Is Nothing) Then
                    file.Dispose()
                End If
                If (Not (sr) Is Nothing) Then
                    sr.Dispose()
                End If
            End Try
        End Function
    End Class

    <System.CodeDom.Compiler.GeneratedCode("System.Xml", "4.8.9037.0"),
     System.Serializable,
     XmlType([Namespace]:="http://ics.dgtaxud.ec/tcl")>
    Public Enum FunctionalErrorCodes

        <XmlEnum("12")>
        Item12

        <XmlEnum("13")>
        Item13

        <XmlEnum("14")>
        Item14

        <XmlEnum("15")>
        Item15

        <XmlEnum("19")>
        Item19

        <XmlEnum("26")>
        Item26

        <XmlEnum("35")>
        Item35

        <XmlEnum("37")>
        Item37

        <XmlEnum("38")>
        Item38

        <XmlEnum("39")>
        Item39

        <XmlEnum("40")>
        Item40

        <XmlEnum("90")>
        Item90

        <XmlEnum("91")>
        Item91

        <XmlEnum("92")>
        Item92

        <XmlEnum("93")>
        Item93
    End Enum
End Namespace
#Enable Warning
