Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
gunny1979
 
Posts: n/a
Default Copying Data forma website


Hi Guys,

I hope someone can help me, I have managed to manipulate a website by
entering some dates into the input boxes then go to another page with
the information I need. I am wondering if anyone knows a macro I can
use to copy the data directly to a new worksheet?? my code is below


Code:
--------------------
Sub HiltonPortsmouth()
Dim ie As Object
On Error GoTo 1
Set objWSS = CreateObject("WScript.Shell")
Set ie = CreateObject("InternetExplorer.Application")

With ie
.Visible = True
.navigate "https://www.hilton.co.uk/Reservation/300_CheckAvailability.jsp?hid=11001839"
Do While busy: DoEvents: Loop
Do While .ReadyState < 4: DoEvents: Loop
With .document.Forms("checkavailabilityform")
.day1.Value = Worksheets("setup").Range("C59").Text
.monthyear1.Value = Worksheets("setup").Range("C60").Text
.day2.Value = Worksheets("setup").Range("C61").Text
.monthyear2.Value = Worksheets("setup").Range("C62").Text
.submit
End With
Set ie = Nothing

Exit Sub

1: MsgBox "Unexpected Error, sorry."
ie.Quit
Set ie = Nothing
End With

End Sub
--------------------


--
gunny1979
------------------------------------------------------------------------
gunny1979's Profile: http://www.excelforum.com/member.php...o&userid=32932
View this thread: http://www.excelforum.com/showthread...hreadid=533707

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
pasting data from a website changes text to date stebro Excel Discussion (Misc queries) 8 August 12th 06 09:39 PM
Copying data form website gunny1979 Excel Discussion (Misc queries) 2 April 3rd 06 02:56 PM
Inserting a new line when external data changes Rental Man Excel Discussion (Misc queries) 0 January 11th 06 08:05 PM
Inserting a new line in spreadsheet Rental Man Excel Discussion (Misc queries) 2 January 9th 06 05:55 PM
copying data Rick, United Kingdom Excel Worksheet Functions 0 August 20th 05 07:44 PM


All times are GMT +1. The time now is 07:55 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"