Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

Ò»¸öasp.netµÄÉú³ÉÇúÏßͼµÄ¹ý³Ì

ÕâÀïÊÇ´ÓDatasetÀïµÄÊý¾ÝÉú³ÉÇúÏßͼ.
ÎÒµÄDatasetÊÇ´Ó±íSendrecÀï¶ÁÈ¡µÄÊý¾Ý,·Ö±ðÓÐId,Sendid(¶©µ¥ºÅ),Sendtime(¼Ç¼ʱ¼ä),Sendnum(µ¥Î»Ê±¼ä·¢ËÍÁ¿/ÎÒÕâÀïÊÇÎå·ÖÖÓ)¼¸¸ö×Ö¶Î
¹ý³ÌÈçÏÂ:
public void draw(Page page,DataSet ds,int Tnum){}
ÆäÖÐpageÊÇÓÃÀ´´«µÝÒýÓÃÕâ¸ö¹ý³ÌµÄÒ³Ãæ,ÕâÑùÈÃÒ³ÃæÊÇJPG·½Ê½Ö±½ÓÏò¿Í»§¶ËÊä³öÉú³ÉµÄÇúÏßͼ.
ds¾ÍÊÇÈ¡³öÀ´µÄÊý¾Ý¼¯ÁË
TnumÖ»ÊÇÎÒÕâÀïÒªÓõ½µÄÒ»¸ö²ÎÊý,²»ÏëÈÃÕâ¸öÀàÈ¥½Ó´¥¶ÁÈ¡¹ý³Ì,ËùÒ԰Ѷ©µ¥µÄ×ÜÁ¿Ö±½ÓÈ¡³öºó´«µÝ¸øËüµÄ.
using System.Drawing.Drawing2D;
using System.Drawing.Imaging;
using System.Drawing;
using System.IO;
public class imgdraw
{
public imgdraw()
{

}
public void draw(Page page,DataSet ds,int Tnum)
{
//È¡µÃ¼Ç¼ÊýÁ¿
int count = ds.Tables[0].Rows.Count;
//¼ÇËãͼ±í¿í¶È
int wd = 80 + 20 * (count - 1);
//ÉèÖÃ×îС¿í¶ÈΪ800
if (wd < 800) wd = 800;
//Éú³ÉBitmap¶ÔÏñ
Bitmap img=new Bitmap(wd,400);
//Éú³É»æͼ¶ÔÏñ
Graphics g = Graphics.fromImage(img);
//¶¨ÒåºÚÉ«»­±Ê
Pen Bp = new Pen(Color.Black);
//¶¨ÒåºìÉ«»­±Ê
Pen Rp = new Pen(Color.Red);
//¶¨ÒåÒø»ÒÉ«»­±Ê
Pen Sp = new Pen(Color.Silver);
//¶¨Òå´ó±êÌâ×ÖÌå
Font Bfont = new Font("Arial", 12, FontStyle.Bold);
//¶¨ÒåÒ»°ã×ÖÌå
Font font = new Font("Arial", 6);
//¶¨Òå´óµãµÄ×ÖÌå
Font Tfont = new Font("Arial", 9);
//»æÖƵ×É«
g.DrawRectangle(new Pen(Color.White, 400), 0, 0, img.Width, img.Height);
//¶¨ÒåºÚÉ«¹ý¶ÉÐͱÊË¢
LinearGradientBrush brush = new LinearGradientBrush(new Rectangle(0, 0, img.Width, img.Height), Color.Black, Color.Black, 1.2F, true);
//¶¨ÒåÀ¶É«¹ý¶ÉÐͱÊË¢
LinearGradientBrush Bluebrush = new LinearGradientBrush(new Rectangle(0, 0, img.Width, img.Height), Color.Blue, Color.Blue, 1.2F, true);
//»æÖÆ´ó±êÌâ
g.DrawString(ds.Tables[0].Rows[0]["sendid"].ToString() + "ºÅ¶©µ¥·¢ËÍÇé¿öÇúÏßͼ", Bfont, brush, 40,


Ïà¹ØÎĵµ£º

ASP.NET¿ª·¢¾­Ñé»ýÀÛ

ÔÚ¿ª·¢¹ý³ÌÖУ¬Í¨¹ýÃþË÷²é×ÊÁÏ£¬ÊÕ¼¯ÁËһЩֵµÃÌá³öÀ´µÄ¾­Ñ飺
1¡¢ Ïà¶ÔÓÚÔ­À´µÄforÓï¾äforeach¾ßÓиüºÃµÄÖ´ÐÐЧÂÊ£¬foreachµÄƽ¾ù»¨·Ñʱ¼äÖ»ÓÐforµÄ30%¡£Í¨¹ý²âÊÔ½á¹ûÔÚforºÍforeach¶¼¿ÉÒÔʹÓõÄÇé¿öÏ£¬ÎÒÃÇÍƼöʹÓÃЧÂʸü¸ßµÄforeach¡£ÁíÍ⣬ÓÃforдÈëÊý¾Ýʱ¼ä´óÔ¼ÊǶÁÈ¡Êý¾Ýʱ¼äµÄ10±¶×óÓÒ£»
2¡¢ ÔÚasp.net³ÌÐòÖУ¬ ......

asp.net ÉÏ´«Îļþ

  if (FileUpload1.HasFile)
            {
                string fileContentType = FileUpload1.PostedFile.ContentType;
       &n ......

ASP.NET 2.0µÄ»º´æ¼¼Êõ¼ò½é

¡¡¡¡ÓÉÊý¾Ý¿âÇý¶¯µÄWebÓ¦ÓóÌÐò£¬Èç¹ûÐèÒª¸ÄÉÆÆäÐÔÄÜ£¬×îºÃµÄ·½·¨ÊÇʹÓûº´æ¹¦ÄÜ¡£Óû§´ÓÊý¾Ý¿âÖмìË÷Êý¾Ý£¬¿ÉÄÜÊÇWebÓ¦ÓóÌÐòÖÐÖ´ÐÐ×îÂýµÄ²Ù×÷Ö®Ò»¡£ÒòΪÆäÖÐÉæ¼°¶à¸ö»·½Ú£¬ÀýÈ磬Web·þÎñÆ÷¡¢Êý¾Ý¿â·þÎñÆ÷µÈ¡£ÓÈÆäÊÇÔÚÓû§±È½Ï¶à£¬¼ìË÷µÄÊý¾ÝÁ¿±È½Ï´óµÄÇé¿öÏ£¬»á¸ø°üÀ¨Óû§ÔÚÄڵĸ÷¸ö·½ÃæÔì³É²»Ð¡µÄÀ§ÄÑ¡£Èç¹ûÄܹ»½«Êý¾Ý¿ ......

ASP.NETÖÐÉÏ´«Îļþµ½Êý¾Ý¿â

SQL½Å±¾£º
CREATE TABLE tblBooksUpload
(
¡¡DocID int NOT NULL IDENTITY Primary Key ,
¡¡DocTitle varchar (200) ,
¡¡Doc image,
¡¡DocType varchar (50) ,
¡¡Entrydate datetime Default GetDate()
)

Ê×ÏÈÎÒÃÇҪʵÏÖÓû§ÔÚä¯ÀÀÆ÷¶Ë×ÔÓÉÑ¡ÔñÎļþ£¬È»ºóÉÏ´«£¬ÕâÀïÓû§Ñ¡ÔñÎļþ£¬µ±È»ÊÇÒªÇó±ê×¼µÄWindows·½Ê½£ ......

asp.netÖÐÓÃsoapheader×÷ÑéÖ¤µÄʹÓò½Ö裺 ºÜ¼òµ¥

Asp.netÒ³ÃæÖе÷ÓÃÒÔSOAPÍ·×÷ÑéÖ¤µÄweb services²Ù×÷²½Ö裺
µÚÒ»²½£ºÓÃÀ´×÷SOAPÑéÖ¤µÄÀà±ØÐë´ÓSoapHeaderÀàÅÉÉú£¬ÀàÖÐPublicµÄÊôÐÔ½«³öÏÖÔÚ×Ô¶¯²úÉúXML½ÚµãÖУ¬¼´£º
<soap:Header>
    <UserSoapHeader xmlns="http://tempuri.org/">
      <UserName>strin ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ