View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
slimswol[_3_] slimswol[_3_] is offline
external usenet poster
 
Posts: 1
Default web query in VBA (format dates in url)


Any other ideas? I am usinmg the query below but I am getting an error
"Application-defined or object-defined error"

Please help



Sub URL_Query()

With
ActiveSheet.QueryTables.Add(Connection:="URL;http://mywebsite.com/abc?name=volform&params=srgEd&status=Open&BeginDat e="
& Format(Now(), "yyyy-mm-dd") & "EndDate=" & Format(Now(),
"yyyy-mm-dd"), Destination:=Range("a1"))

..BackgroundQuery = True
..TablesOnlyFromHTML = True
..Refresh BackgroundQuery:=False
..SaveData = True
End With
End Sub


--
slimswol
------------------------------------------------------------------------
slimswol's Profile: http://www.excelforum.com/member.php...o&userid=32014
View this thread: http://www.excelforum.com/showthread...hreadid=517569