Forum Discussion
Preserve cell fill color when importing from web
In that case, you may be able to scrape the colour value fom the website HTML.
In Power Query you can use the Web connector dialog to pick out HTML segments from websites so you could, in theory, identify the colour along with the value, but I've never done it that in-depth before myself and sounds like it could get quite fiddly.
Have a go at connecting to the site using the web connector then see if you can identify the correct part of the HTML using the 'Table From Examples' button.
Pete
I have tried to do it, but it seems that from power query for excel the HTML cannot be accessed, only from the desktop. Also, the "Add using examples" button does not appear. Any other ideas? Thank you so much
- BA_Pete3 years ago
Super User
I've just tested on M365 v2301 and you're right, Excel seems to be using a slightly de-functioned version of Power Query.
I don't know what to suggest in that case I'm afraid. Maybe install Power BI Desktop and see if you can do what you need from there?
Beyond that, you may need to use a more advanced scraping method, perhaps a third-party app or Pthon script?
Pete