Convert CSS to Image

Yusuf 791 Reputation points
2021-09-03T14:30:35.063+00:00

Hi
I am using htmlrenderer.WinForms to save CSS as Image

Convert CSS to image in C#

CSS code

     .bg{

background-image: linear-gradient(90deg, rgb(235, 216, 9),rgb(202, 60, 134));
}

but CSS not showing in image just white color.

Developer technologies .NET .NET CLI
Developer technologies C#
0 comments No comments
{count} votes

Accepted answer
  1. Castorix31 90,521 Reputation points
    2021-09-03T15:24:00.507+00:00

    It works if I add at the beginning of the HTML source : (remove space after < (I cannot copy-paste correctly...))

    < meta http-equiv="X-UA-Compatible" content="IE=edge">

    129156-css-in-webbrowser.jpg

    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.