?
Solved

Reading content from embedded active x web browser.

Posted on 2005-03-03
2
Medium Priority
?
293 Views
Last Modified: 2013-11-25
Hi,

I have a vb form with an embedded IE browser of which I can post data to text boxes, submit, and then read data back from text boxes via VB.

I am using the following for this:
ActiveXCtl8.Navigate "http://www.blagblahblah.co.uk/test.php"
Dim htmdoc As HTMLDocument
Set htmdoc = ActiveXCtl8.Document
htmdoc.Forms(0).all("form_name").Value = "bob"
htmdoc.Forms(0).all("form_age").Value = 55
htmdoc.Forms(0).submit

This is working fine, but I need to be able to read other text from the browser that is not in a text box, ie normal html text in the browser. It does not matter if I can only read the text shown of the raw html as I can extrapolate what I need from either.

Any help or advice on this would be greatly appreciated.

(btw: apologies for only 350 points, but I have very few left)

Kind Regards

C
0
Comment
Question by:chris_msl
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 43

Accepted Solution

by:
TimCottee earned 1400 total points
ID: 13447730
Hi chris_msl,

Presumably you can get htmdoc.innerHTML property. This should give you the raw HTML for the entire page. If you can then parse this to get your data you are done.

It all depends where the rest of the info is, if it is contained in other html elements then you can use a similar method to extract the info just by using the tag's name property as you are doing with the form:

htmdoc.all("somecontrol").value

Tim Cottee
0
 

Author Comment

by:chris_msl
ID: 13447908
Hi Tim,

Many thanks for this works a treat

Kind Regards

C
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

800 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question