C# code to get the Thumbnail image for the uploaded Power point template(.POT) file? RRS feed

  • Question

  • Hi,
       Iam uploading a Powerpoint template file(.pot) and i want to get the thumbnail for the first slide of the uploaded .pot file.

    Iam able to get the Thumbnail of the uploading image by using this code:
    System.Web.HttpContext.Current.Response.ContentType = "image/jpeg";
    image = System.Drawing.Image.FromStream(new System.IO.MemoryStream((byte[])dsSkinColor.Tables[0].Rows[0]["I_Image"]));
    System.Int32 _width = image.Width;
    System.Int32 _height = image.Height;
    System.Drawing.Image _newimage = image.GetThumbnailImage(_width, _height, null, new System.IntPtr());
    _newimage.Save(System.Web.HttpContext.Current.Response.OutputStream, System.Drawing.Imaging.ImageFormat.Jpeg);

    But, Iam not able to get the Thumbnail of the Powerpoit Template file. Could somebody help me to send code to retrieve the Thumbnail image for the uploaded .POT file.

    • Moved by nobugz Monday, June 22, 2009 11:26 AM not a bcl q (From:.NET Base Class Library)
    Monday, June 22, 2009 7:14 AM


All replies