how to manipulate Image.Formstream(str)

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Gunnasssubash

    #1

    how to manipulate Image.Formstream(str)

    I have used using System.Web.UI.W ebControls; namespace, but this Image.FromStrea m() method is erroe, What is solution of this, How to solve this problem.


    This is my code
    Code:
     byte[] imageBytes = Convert.FromBase64String(txtBarcode.Text);
                    MemoryStream ms = new MemoryStream(imageBytes, 0,imageBytes.Length);
                    ms.Write(imageBytes, 0, imageBytes.Length);
                    Image image = Image.FromStream(ms, true);
    This is error message
    Compiler Error Message: CS1729: 'System.Web.UI. WebControls.Ima ge' does not contain a constructor that takes '2' arguments

    Source Error:
    Image image = Image.FromStrea m(ms, true);



    Thanking you,

    Gunnas
Working...