0

I want to display one image in the format of System.Drawing.Bitmap in Webpage.

here i used,

var file12 = TagLib.File.Create(file);

if (file12.Tag.Pictures.Length >= 1)
{
    var bin = (byte[])(file12.Tag.Pictures[0].Data.Data);
    if (bin.Length > 0)
    {
        Images = System.Drawing.Image.FromStream(new MemoryStream(bin)).GetThumbnailImage(200, 200, null, IntPtr.Zero);
        album = file12.Tag.Album;
    }
}

in that Images variable,System.Drawing.Bitmap format is there,i want to dislpay that image to webpage in C#

Yurii
  • 4,811
  • 7
  • 32
  • 41
Arumugam
  • 23
  • 6
  • Web browsers want to load images themselves, from URIs. You'll need to save the image in some way and then provide a suitable URI in the `src` attribute of an `img` tag. If you don't want to store it permanently on disk, then you probably will want to save the image to a `MemoryStream`, then convert the `byte[]` to a Base-64 string and generate a [data URI](http://en.wikipedia.org/wiki/Data_URI_scheme). – Damien_The_Unbeliever Jan 08 '14 at 07:42
  • Please do not post same question more than once, you can always edit your own question to add more information or to refine your question! – Adriano Repetti Jan 08 '14 at 10:37

0 Answers0