I'm struggling with submission of a web form.
<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com
ffice
ffice" /><o
></o
>
The goal: to summarize the next earnings date of a list of companies based upon their ticker symbols which reside in a column of my spreadsheet. Eventually I'll loop this code across several tickers, but for now I'm working on one coded symbol.
<o
></o
>
The problem: It appears that the host page does not allow the use of .submit as I get an error from Briefings.com which states "Request Not Allowed (405-HTTP verb used to access this page is not allowed)"
<o
></o
>
<o
></o
>
Here's a copy of my current macro.
<o
></o
>
<o
></o
>
<o
></o
>
<o
></o
>
I've struggled with this macro for a couple of days now. I've tried entering the info using Sendkeys rather than the Item(1) definition and .Submit but to no avail. Seems like it'd be a simple macro, but I'm just not getting it. I've also tried manipulating .document.forms(1). However, forms(1) generates a pop-up-window (a second instance of Internet Explorer) which I cannot seem to access within my code which has access to the initial IE window and not the newly generated one.
<o
></o
>
Any help would be greatly appreciated. I'm even proposing to immortalize the one who solves this by naming my subroutine after you . . . sub your_name_here().
Thanks,
Necessity
<o
></o
>
<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com
The goal: to summarize the next earnings date of a list of companies based upon their ticker symbols which reside in a column of my spreadsheet. Eventually I'll loop this code across several tickers, but for now I'm working on one coded symbol.
<o
The problem: It appears that the host page does not allow the use of .submit as I get an error from Briefings.com which states "Request Not Allowed (405-HTTP verb used to access this page is not allowed)"
<o
<o
Here's a copy of my current macro.
<o
Rich (BB code):
Sub earnings_date_finder()
dim ie as object
dim ticker as string
dim chartpage as string
<o:p></o:p>
ticker = "ESI"
chartpage = "http://www.briefing.com/Investor/Private/Calendars/EarningsGuidanceCalendar.htm"
<o:p></o:p>
Set ie = CreateObject("internetexplorer.Application")
With ie
.Visible = True
.navigate chartpage
Do While .Busy: DoEvents: Loop
Do While .ReadyState <> 4: DoEvents: Loop
.document.forms(0).Item(1).Value = ticker
.document.forms(0).submit
Do While .Busy: DoEvents: Loop
Do While .ReadyState <> 4: DoEvents: Loop
<o:p></o:p>
'here is where I would manipulate the .document.body.innertext to extract info from the page . . . if it loads without error.
<o:p></o:p>
End With
Set ie = Nothing
End Sub
<o
<o
I've struggled with this macro for a couple of days now. I've tried entering the info using Sendkeys rather than the Item(1) definition and .Submit but to no avail. Seems like it'd be a simple macro, but I'm just not getting it. I've also tried manipulating .document.forms(1). However, forms(1) generates a pop-up-window (a second instance of Internet Explorer) which I cannot seem to access within my code which has access to the initial IE window and not the newly generated one.
<o
Any help would be greatly appreciated. I'm even proposing to immortalize the one who solves this by naming my subroutine after you . . . sub your_name_here().
Thanks,
Necessity
<o