EDUCATED MONKEY
Board Regular
- Joined
- Jul 17, 2011
- Messages
- 218
The set up is office 2007 windows XP professional IE8<?xml:namespace prefix = o ns = "urn:schemas-microsoft-comfficeffice" /><o></o>
At present I have an HTTP string which I dispatch via InternetExplorer.application the data is then sent back as xml and is pasted in the column A
This bit work fine. <o></o>
The part I am having problems with is using the from xml data import option,on the from other sources tab, if I manualy save the xml file to drive C then locate it as part of the import everything works perfectly<o></o>
So what I need to do is make the worksheet the source then it will accomplish the task
At present I have an HTTP string which I dispatch via InternetExplorer.application the data is then sent back as xml and is pasted in the column A
This bit work fine. <o></o>
The part I am having problems with is using the from xml data import option,on the from other sources tab, if I manualy save the xml file to drive C then locate it as part of the import everything works perfectly<o></o>
So what I need to do is make the worksheet the source then it will accomplish the task
Rich (BB code):
Sub XMLCONTROL()
Rich (BB code):
Rich (BB code):
'
' XMLCONTROL Macro
'
' Keyboard Shortcut: Ctrl+Shift+Z
'
Dim Q As String
Dim aurl As String
Dim EXP
aurl = Worksheets("CONTROL").Range("C2").Value ' pass HTTP string in
Set EXP = CreateObject("InternetExplorer.application")
EXP.Visible = True
EXP.Navigate (aurl)
Application.Wait (Now + TimeSerial(0, 0, 5))
SendKeys "^a"
SendKeys "^c"
Application.Wait (Now + TimeSerial(0, 0, 5))
Worksheets("TEST XML").Activate
Worksheets("TEST XML").Range("A1").Select
ActiveSheet.PasteSpecial Format:="Text", LINK:=False, DisplayAsIcon:= _
False
Call CloseIE
End Sub
Last edited: