NO IMAGE

/// <summary>
    /// 圖片轉換成位元組流
    /// </summary>
    /// <param name=”img”>要轉換的Image物件</param>
    /// <returns>轉換後返回的位元組流</returns>
    public static byte[] ImgToByt(Image img)
    {
        MemoryStream ms = new MemoryStream();
        byte[] imagedata = null;
        img.Save(ms, System.Drawing.Imaging.ImageFormat.Jpeg);
        imagedata = ms.GetBuffer();
        return imagedata;
    }
    /// <summary>
    /// 位元組流轉換成圖片
    /// </summary>
    /// <param name=”byt”>要轉換的位元組流</param>
    /// <returns>轉換得到的Image物件</returns>
    public static Image BytToImg(byte[] byt, string imgUrl)
    {
        MemoryStream ms = new MemoryStream(byt);
        Image img = Image.FromStream(ms);
        img.Save(imgUrl);
        return img;
    }
    //
    /// <summary>
    /// 根據圖片路徑返回圖片的位元組流byte[]
    /// </summary>
    /// <param name=”imagePath”>圖片路徑</param>
    /// <returns>返回的位元組流</returns>
    private static byte[] getImageByte(string imagePath)
    {
        FileStream files = new FileStream(imagePath, FileMode.Open);
        byte[] imgByte = new byte[files.Length];
        files.Read(imgByte, 0, imgByte.Length);
        files.Close();
        return imgByte;
    }