Re: retrieve data from an .aspx web page

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance




Answer: The 2nd instance was from another macro that I forgot to delete
1. I notice two instances of IE. I'm wondering the
purpose of opening two instances.

Set IE = CreateObject("InternetExplorer.Application")
IE.Visible = True

Set IE2 = CreateObject("InternetExplorer.Application")
IE2.Visible = True

Answer: The dump is something I use for debugging. It is not necessary.
the dump requires a worksheet called "Dump"
2. I'm not clear what to do with The Call Dump(IE)
section.

The code doesn't select the object, jst displays the contents of the object.
didn't know what you need the object for.
If I click "Ok" on the message boxes, the
"Select Company" drop down is not selected. Then 4
more message boxes are activated--Glenair,
ElectroAdapter, etc. I click the OK button each
time, but no data is written to the "Dump" sheet.

Answer : The macro isn't interactive with the webpage.

If I select the company name as the Message box
directs, the "Call Dump" code returns an error
Run-time error '70': Permission Denied. No line of
code is highlighted that I can tell.

Answer : Once you naviagate to another webpage the VBA code doesn't
recognize the new object. the VBA code would have to perform the action.

3. I'm not seeing the results I expected. I am hoping
to see a Glenair Series and it's corresponding
Amphenol Series. There is another level deeper
where the site generates an entire Amphenol
part number. I don't know if this level is
accessible.

Anwer : The webpage object has a property "Document" and the another
property below the document called all. The dump code is putting 4 of the
all poperties on the worksheet

Column A : The Tagname property
Column B : The ID property
Column C : The classname property
Column D : the 1st 1024 characters of the innertext property. Excel
creates an error when the string size gets too long

There are more properties if you add itm to the watch window you will see
additional items.

4. The code does return data, but I don't understand
the data. For example: the following data is
written to cell D2:

You sould look at the source code of the webpage by going to the IE menu

View - Source
or
Tools - Developer tools F12


I don't know what you wanted to do and just got you started. I assumed if
you need more details you would ask. It is hard sometimes from one question
to know a persons skill level.
.



Relevant Pages

  • Re: HELP: SQL in Excel VBA
    ... I had a macro that went through each column and counted how many rows were ... I previously used the pre-2007 code to dump data which worked great but now ... with the 2007 version of the code, it appears the data is treated as a pivot ... I had to change the code for doing the sql because the old code didn't like ...
    (microsoft.public.excel.programming)
  • Re: utility that will dump a web page to std out?
    ... you can also use Lynx with the -dump option. ... >> Does anyone know of a utility that will get a webpage and dump the ... they must first drive mad. ...
    (freebsd-questions)
  • Re: Extracting text of queries (SQL) and Macros?
    ... "dump" (serialization) of Access's objects and configurations, ... especially query SQL text and macro names and parameters? ...
    (microsoft.public.access.conversion)
  • Re: Is VS 2005 "plugginable"?
    ... macro that can dump this kind of info? ... Btw, I forgot to add that VC is plugin-able through vsip. ...
    (microsoft.public.vc.language)
  • Question about replacing a spreadsheet
    ... I've got an Excel spreadsheet that's got a macro in it. ... Does anybody have any experience with this sort of thing who ... the data into a big grid of some kind. ... The idea is to dump a bunch of data into this, run the macro, ...
    (borland.public.delphi.thirdpartytools.general)