hi
i have created a sample
public void ConvertHtmlToImage()
i have created a sample
public void ConvertHtmlToImage()
{
Bitmap m_Bitmap = new Bitmap(400, 600);
PointF point = new PointF(0, 0);
SizeF maxSize = new System.Drawing.SizeF(500, 500);
CssData css = HtmlRenderer.CssData.Parse("font-family:italic,background-color:Yellow;san-serif;font-size:100px;",true);
var img = HtmlRender.RenderToImage(File.ReadAllText(@"D:\html.txt"), 600);
HtmlRenderer.HtmlRender.Render(Graphics.FromImage(m_Bitmap),"<html><body><div><div>Hello World, Converting Html To Image!!!</div></div></body></html>",
point, maxSize,css);
m_Bitmap.Save(@"D:\Test.png", ImageFormat.Png);
createAutoHeightImage(myHTML,1);
}
css is not applying for this one and can you help me how can i use external stylesheet i am very new to this one