Graphics myGraphics = this.CreateGraphics(); Bitmap myBitmap = new Bitmap(60, 20);
myGraphics = Graphics.FromImage(myBitmap);
myGraphics.FillRectangle(new SolidBrush(Color.White), 0, 0, 60, 20);
myGraphics.DrawString("3365.0", new Font("Arial", 12), new SolidBrush(Color.Black), new Point(0, 2));怎么样再将图形数据转换为二进制数据
myGraphics = Graphics.FromImage(myBitmap);
myGraphics.FillRectangle(new SolidBrush(Color.White), 0, 0, 60, 20);
myGraphics.DrawString("3365.0", new Font("Arial", 12), new SolidBrush(Color.Black), new Point(0, 2));怎么样再将图形数据转换为二进制数据
myBitmap.Save(mms, System.Drawing.Imaging.ImageFormat.Bmp);
var bt = new byte[mms.Length];
mms.Position = 0;
mms.Read(bt, 0, Convert.ToInt32(bt.Length));
myBitmap.Save(mms, System.Drawing.Imaging.ImageFormat.Bmp);
bytes[] rr=mms.ToArray();