Hello.
How can I do to get the screenshot of an element, DIV, BUTTON, INPUT, etc. and then use that image in my delphi application?
Which is the best or easiest way to do it? Using javascript? Using OSR Chrome?
Thanks
Disclosure Statement: This site contains affiliate links, which means that I may receive a commission if you make a purchase using these links. As an eBay Partner, I earn from qualifying purchases.
Screenshot of element
- salvadordf
- Posts: 4580
- Joined: Thu Feb 02, 2017 12:24 pm
- Location: Spain
- Contact:
Re: Screenshot of element
Hi,
You can use the demo you like most because you can take screenshots in normal mode or OSR mode.
If you just want to take the screenshot of one element then you would need to crop the screenshot of the whole web browser using the element coordinates and size.
In order to get the element coordinates and size I would recommend using JavaScript and then send the coordinates and size back to the browser using the "console trick" that you have on the DOMVisitor demo.
You can use the demo you like most because you can take screenshots in normal mode or OSR mode.
If you just want to take the screenshot of one element then you would need to crop the screenshot of the whole web browser using the element coordinates and size.
In order to get the element coordinates and size I would recommend using JavaScript and then send the coordinates and size back to the browser using the "console trick" that you have on the DOMVisitor demo.