cancel
Showing results for 
Search instead for 
Did you mean: 

Capture text from webpage

Highlighted
Not applicable

Capture text from webpage

HI,



I'm a new user and am looking for a way to capture text from a webpage into a VBA variable.

Do I  have to get it from the source code? If I have to capture all the source code, that's fine as I can extract what I need in the script.  



Any suggestions.



Thanks



Martin
h
2 REPLIES 2
Highlighted
Staff

RE: Capture text from webpage

It seems that page.contentDocument.documentElement.innerText or page.contentDocument.documentElement.textContent is what you need.
Highlighted
Staff

RE: Capture text from webpage

if you just need to capture some values on the page, and not the whole page, you can use a Log Event to capture the object's text property as well. If you running a loop test, it captures the data on each cycle and creates a log entry in the test results.
New Here?
Join us and watch the welcome video:
Announcements
Join TechCorner Challenge!
Want a fun and easy way to learn TestComplete? Try solving weekly TechCorner challenges and get into the Leaderboard!


Challenge Status

Compare images using the Region Checkpoint

See replies!

Converting UTC TimeDate in an Excel file

See replies!

Compare HTML table with Excel file and correct data in Excel file

Participate!

How to execute remote test and obtain results via Test Runner REST API

Participate!
Top Kudoed Authors