0

I am sending mails of this html created page, but that page design is changed in outlook. so i am trying to convert this html source to image and send mails.

so I have stored html source in string variable like this.

string Str1 = "<table id='myTable3' style='width:100%;background-color: #4B4B4B;border:2px solid #8b8b8b;padding:0% 2% 0% 0%;margin-top:2% !important;'><tbody><tr><td style='text-align:left;padding:2% 0% 0% 2%;font-size:20px;color:#6BB6E7;font-weight:600;'></td></tr> </tbody></table>"; 

i have tried using this solution but it is not working.

so how can i convert this html source into image?

Community
  • 1
  • 1
Nikhil
  • 19
  • 2
  • how are you sending the mail? for `System.Net.Mail`, there will be a property `IsBodyHtml` for `MailMessage` which you need to set to true to render the html properly – Developer Dec 14 '16 at 04:51
  • @Developer i have set IsBodyHtml property is true already. – Nikhil Dec 14 '16 at 04:57
  • Sorry, I read your question wrong. What you need is a solution to convert the dynamic html to image on the fly. prob `BitMap` should help you in this case – Developer Dec 14 '16 at 05:04

1 Answers1

1

Fire gimp or any other image manipulation program. Even pain will do on Widows(missing n err) and type the string. Save as png or jpeg.

Shiv
  • 1,912
  • 1
  • 15
  • 21