How to import data from xml to excel sheet using macros (1 Viewer)

Manukrrish

New member
Local time
Tomorrow, 02:34
Joined
Jul 11, 2012
Messages
1
Hi I am working on How to import data from xml to excel sheet using macros,
i am using MS2003, i wrote below code for it

Sub ImportXMLtoList()
Dim strTargetFile As String
Application.DisplayAlerts = False
strTargetFile = "C:\BookData.xml"
Workbooks.OpenXML Filename:=strTargetFile, LoadOption:=xlXmlLoadImportToList
Application.DisplayAlerts = True
End Sub
But when i run the a pop saying "The specified XML Source Doesnt refer to a schema.Excel will create schema based on the XML source data" is displayed, when i click ok button then Nothing is pasted in Excel.

Please help in this
 
Welcome aboard:)
I moved this post to the macro section since you requested a macro solution.
 

Users who are viewing this thread

Back
Top Bottom