SolidBrush drawBrush = new SolidBrush(Color.SkyBlue);
Font drawFont = new Font("宋体",4 , FontStyle.Bold, GraphicsUnit.Millimeter);
// int xPos = bmpBackGround.Height - ( bmpBackGround.Height-25 );
int xPos = bArrow.Width+50;//输入的文字位置
int yPos = 3;
g.DrawString (oDr["PROGRESS_TITLE"].ToString(), drawFont, drawBrush, xPos, yPos);
这个color属性我想从数据库里取 但是solidbrush只有color这个属性 我该怎么办啊?或者有什么别的方法?在线等,急啊,各位帮帮忙吧,十分感谢!!!
Font drawFont = new Font("宋体",4 , FontStyle.Bold, GraphicsUnit.Millimeter);
// int xPos = bmpBackGround.Height - ( bmpBackGround.Height-25 );
int xPos = bArrow.Width+50;//输入的文字位置
int yPos = 3;
g.DrawString (oDr["PROGRESS_TITLE"].ToString(), drawFont, drawBrush, xPos, yPos);
这个color属性我想从数据库里取 但是solidbrush只有color这个属性 我该怎么办啊?或者有什么别的方法?在线等,急啊,各位帮帮忙吧,十分感谢!!!
int 红,绿,蓝; //从数据库来
Color c = Color.FromArgb(红, 绿, 蓝);//或者
int colorString = "#ff00ff"; //从数据库来
int colorref = Convert.ToInt32(colorString.SubString(1), 16));
Color c = Color.FromArgb( colorref );SolidBrush drawBrush = new SolidBrush( c );