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

ÓÃasp.net·¢ËÍÓʼþ£¬²âÊԳɹ¦

//Ò»£ºÓÃ×Ô¼ºµÄ·þÎñÆ÷×÷ΪÓʼþ·þÎñÆ÷ʱ£º
//Èç³öÏÖ£ºÓÊÏä²»¿ÉÓᣠ·þÎñÆ÷ÏìӦΪ: 5.7.1 Unable to relay for ***@gmail.com
//½â¾ö°ì·¨ÈçÏ£ºÔÚIISÖУ¬ÓÒ»÷“ĬÈÏSMTPÐéÄâ·þÎñÆ÷”£¬Ñ¡Ôñ“ÊôÐÔ”£¬Çл»µ½“·ÃÎʔҳ£¬µã»÷“Öм̔°´Å¥£¬ÔÚµ¯³ö¿òÖÐÑ¡Ôñ“½öÒÔÏÂÁбí³ýÍ┣¬È·¶¨¡£
//¶þ£ºÓÃÆäËüµÄÓʼþ·þÎñÆ÷·¢ËÍ£¬¾­²âÊÔ´ó¶àÊýÃâ·ÑÓÊÏ䶼²»ÌṩSMTP·þÎñ£¬ÓÃqqÓÊÏäµÄ¾Í¿ÉÒÔ£¬·½·¨£º½øÈëqqÓÊÏ䣭£­£¾ÉèÖã­£­£¾ÕÊ»§£­£­£¾¿ªÍ¨POP3/IMAP/SMTP·þÎñ£¬¼´¿ÉÓÃsmtp.qq.com×÷ΪÓʼþ·þÎñÆ÷ÁË£¬¿ÉÓÃËüÀ´·¢ËÍÓʼþ
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Net.Mail;
public partial class _Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
    }
    public void SendSMTPEMail(string strSmtpServer, string strfrom, string strfromPass, string strto, string strSubject, string strBody)
    {
        System.Net.Mail.SmtpClient client = new SmtpClient(strSmtpServer);
        client.UseDefaultCredentials = false;
        client.Credentials = new System.Net.NetworkCredential(strfrom, strfromPass);
        client.DeliveryMethod = SmtpDeliveryMethod.Network;
        System.Net.Mail.MailMessage message = new MailMessage(strfrom, strto, strSubject, strBody);
        message.BodyEncoding = System.Text.Encoding.UTF8;
        message.IsBodyHtml = true;
        client.Send(message);
    }
    //µÚÒ»¸ö²ÎÊýÊÇÓÊÏä·þÎ


Ïà¹ØÎĵµ£º

asp.netÒ³Ãæ´íÎó´¦Àí

asp.net´íÎó´¦Àí·½·¨ ´ó²¿·Ö¶¼Óà try catch
ÎÒÃÇÒ²¿ÉÒÔÔÚÒ³Ã涨Òå  protected void Page_Error(object sender, EventArgs e)·½·¨´¦Àí´íÎóÐÅÏ¢
{
 //ÏÈ»ñÈ¡µ±Ç°·¢ÉúÒì³£
  Exception ex = Server.GetLastError().GetBaseException();
        if (ex is ArgumentOu ......

ASP.NET¿Ø¼þ¿ª·¢»ù´¡Ö®ÊµÏֿؼþ¼¯ºÏÊôÐÔ

¼¯ºÏÊôÐÔÏàÐÅ´ó¼Ò¶¼ºÜÊìϤҲºÜ³£ÓÃ,ÈçDropDownList,ListBoxµÈ¿Ø¼þ
﹤asp:DropDownList ID="DropDownList1" runat="server"﹥              ﹤asp:ListItem﹥²âÊÔ1﹤/asp:ListItem﹥    & ......

asp.net 1.1 °²×°ÊÖ²á


 
ÏÈÉý¼¶ieµ½5.5°æÒÔÉÏ
1 ÏÂÔØÖÐÎÄ°æIE6:http://download.microsoft.com/download/ie6sp1/finrel/6_sp1/W98NT42KMeXP/CN/ie6setup.exe
2 ÏÂÔØmdac°²×° Ö±½ÓÏÂÔØ2.8ÖÐÎÄ°æ:http://download.microsoft.com/download/8/b/6/8b6198c0-fe96-4811-9d81-d5c76dd5fea8/MDAC_TYP.EXE
3 È»ºóÏÂÔØ.NET Framework 1.1°æ¿ÉÔÙ· ......

ASP.NETÓÚExcelµÄ½»»¥

public DataSet ExcelToDS(string Path)
{
string strConn = "Provider=Microsoft.Jet.OLEDB.4.0;" + "Data Source=" + Path + ";" + "Extended Properties=Excel 8.0;";
OleDbConnection conn = new OleDbConnection(strConn);
conn.Open();
string strExcel = "";
Ole ......

Asp.NetÖÐHttpMoudule³õʼ»¯³ÌÐò

ΪÁËÍü¼Ç:
1,System.Web.Hosting.ISAPIRuntime.ProcessRequest(IntPtr, Int32);:void
//´ÓIISÀ´µÄÇëÇó
2,System.Web.HttpRuntime.ProcessRequestInternal(HttpWorkerRequest) : Void
//ÔÚÕâÒ»²½´´½¨Ò»¸öHttpContext¶ÔÏó
3, System.Web.HttpApplicationFactory.GetApplicationInstance(HttpContext) : IHttpHandler
// ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ