cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
pirdim Frequent Visitor
Frequent Visitor

Web.BrowserContents - how to force web page to load all pictures

Hello everyone,

 

I am trying to take info about products from web page using so-called "web by example connector". So I use Web.BrowserContents method. Eventually I am able to get what I need except the url of a product image. When I insepct html code while I check page in Chrome I see that I need class "product-media _img _imgImpressions _imageLoaded", "src" field contains required url. But in html code loaded by this method in PowerBI for most products I have shorter class "product-media _img _imgImpressions" without "_imageLoaded". Only 2 first products have "_imageLoaded". So only for 2 first products I have url of their picture and for all others I have some template url, same for all. 

 

I've tried to use WaitFor field of Web.BrowserContents method. It gives an opportunity to check whether some CSS Selector exists on page. But the problem that selector "img._imageLoaded" does exist on page but only for 2 products, not all of them. So this field didn't help. I am not super experienced in Power BI and know nothing about html. Maybe you can suggest some idea how to avoid this trouble?

 

 

I have a workaround to go to each product page and take image url from there. But it works super slowly. I need to take data from 1 page with all products on it.

4 REPLIES 4
Community Support Team
Community Support Team

Re: Web.BrowserContents - how to force web page to load all pictures

@pirdim,

 

You could also create a support ticket for assistance.

 

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
pirdim Frequent Visitor
Frequent Visitor

Re: Web.BrowserContents - how to force web page to load all pictures

 @v-chuncz-msft,

 

I am not a pro user. I make it more out of curiousity to see what I can do with this instrument in a future.

Ehren Regular Visitor
Regular Visitor

Re: Web.BrowserContents - how to force web page to load all pictures

Hi @pirdim. The issue is that the images are loaded lazily based on the user scrolling, and if no scrolling occurs, the images are never loaded. There's currently no way to trigger PQ's internally hosted web browser to scroll, click, or perform other actions (for security reasons). So I don't think you'll be able to get this scenario to work.

 

Ehren

pirdim Frequent Visitor
Frequent Visitor

Re: Web.BrowserContents - how to force web page to load all pictures

@Ehren,

thanks for your reply. 

Helpful resources

Announcements
Community Highlights

Community Highlights

Find out what's new in the Power BI Community!

Summit North America

Power Platform Summit North America

Register by September 5 to save $200

Virtual Launch Event

Microsoft Business Applications Virtual Launch Event

Watch the event on demand for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

MBAS Gallery

Watch Sessions On Demand!

Continue your learning in our online communities.

Users Online
Currently online: 6 members 1,861 guests
Please welcome our newest community members: