您好我想顯示的圖像,創造動態使用GDI + 這是我的代碼問題與OutputStream的
Font font = new Font("Impact", 20, FontStyle.Regular);
Bitmap image = new Bitmap(300,50);
Graphics g = Graphics.FromImage(image);
g.DrawString("This is a test", font, Brushes.Blue,10,5);
image.Save(Response.OutputStream, System.Drawing.Imaging.ImageFormat.Gif);
g.Dispose();
image.Dispose();
問題是,當我使用的是Firefox的輸出是這樣的:
但在IE瀏覽器中顯示正確(未在任何其他瀏覽器中測試)。什麼是錯誤。?
顯示使用的代碼在你的default.aspx.cs – Blachshma 2013-03-07 09:06:02
頁它只是在Page_Load事件 – Rakesh 2013-03-07 09:10:04