Sub ImportXMLSchema() Dim xmMap As XmlMap Application.DisplayAlerts = False Set xmMap = ActiveWorkbook.XmlMaps.add("C:\invoice.xml", "Invoice") Application.DisplayAlerts = True xmMap.AdjustColumnWidth = False xmMap.PreserveNumberFormatting = True Set xmMap = Nothing End Sub