ASP.NETÔõÑù½«×¢²áÐÅϢдÈëAccess
רßøÄãдÁ˸ö£¬Ä㿴һϣ¬ËµÃ÷ÏÂÕâÀïûÓп¼Âǵ½Êý¾ÝµÄÓÐЧÐÔ£¬ÐèÒªµÄ»°×Ô¼º¼ÓÉÏ¡£
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.Data.OleDb; //ÕâÀïÒªÒýÓÃOleDb¿Õ¼ä
public partial class Default4 : System.Web.UI.Page
{
//Êý¾Ý¿âÁ¬½Ó×Ö·û´®
static string strCon = @"provider = Microsoft.Jet.OLEDB.4.0;Data source = C:\Documents and Settings\Administrator\×ÀÃæ\db1.mdb";
//ÉêÃ÷Á¬½ÓÊý¾ÝÔ´µÄ¶ÔÏóºÍ¶ÔÊý¾ÝÔ´½øÐвÙ×÷µÄ¶ÔÏó
OleDbConnection con = new OleDbConnection(strCon);
OleDbCommand cmd = new OleDbCommand();
//µã»÷°´Å¥Ìí¼Ó¼Ç¼
protected void Button1_Click(object sender, EventArgs e)
{
string name = TextBox1.Text.Trim(); //ÐÕÃû
string sex = TextBox2.Text.Trim(); //ÐÔ±ð
string QQ = TextBox3.Text.Trim(); //QQ
string email = TextBox4.Text.Trim(); //Email
//Òª²åÈë¼Ç¼µÄsqlÓï¾ä
string insertText = "insert into info(ÐÕÃû,ÐÔ±ð,QQ,ÓÊÏä) values('" + name + "','" + sex + "','" + QQ + "','" + email + "')";
//Êý¾ÝÔ´´ò¿ª
con.Open();
//ÉèÖòÙ×÷¶ÔÏóµÄÊý¾ÝÔ´
cmd.Connection = con;
//ÒªÖ´ÐеÄSQLÓï¾ä
&nb
Ïà¹ØÎĵµ£º
1. ͼƬÎÊÌâ
·Ç³£ºÃ½â¾ö
<img runat="server" src="~/images/ad468x60.gif" alt="" />
¼ÓÉÏrunat="server" £¬Â·¾¶Ê¹Óþø¶Ô·¾¶~/»ù±¾ÉϾÍOKÁË¡£
2. CSSÎļþÒýÓÃ
<link rel="stylesheet" type="text/css" href="style.css" />
ÕâÀïÉñÆæµÄ¾ÍÊÇlinkµÄÎļþµÄhrefÊÇËæ×ű»·ÃÎÊÎļþµÄĿ¼½á¹¹×Ô¶¯µ÷Õû£¬Ëµ°×Á˾ ......
viewÔÚMVCģʽÖÐÓëÓû§½øÐÐ×îÖ±½ÓµÄ½Ó´¥£¬Ëü¸ºÔðÊý¾ÝµÄ³ÊÏÖ¡£ÕâÀïҪעÒâÒ»µã¾ÍÊÇ£¬viewÖ»ÊǸºÔðÊý¾ÝµÄ³ÊÏÖ£¬ËùÒÔÎÒÃÇÓ¦¸ÃÒª¾¡Á¿ÈÃ
viewÖв»Éæ¼°ÒµÎñÂß¼µÄ´¦Àí¡£
ÎÒÃÇÀ´Ìí¼ÓÒ»¸öBlogÊ×Ò³µÄview¡£ÔÚ°²×°ÁËASP.NET MVCºó£¬ÎÒÃÇÔÚÌí¼ÓÐÂÏîÄ¿µÄʱºò¿ÉÒÔ¿´µ½ÓÐMVCµÄviewÄ£°å£º
×¢£ºÈç¹ûÄãµÄÊÇÖÐÎÄ°æ
µÄVS£¬°²×°Íêºó¿ ......
¶ÁÈ¡SAPÊý¾Ý, ´ÓÁ½·½ÃæÀ´×ö
1) ×öÒ»¸öC# app ÔÚ·þÎñÆ÷ÉÏ"ÈÎÎñ¼Æ»®"ÿÌì¶ÁÈ¡. ±ØÐëÔÚ·þÎñÆ÷ÉÏÖ´ÐÐ, ·ñÔò¿ÉÄÜ´ÓSAP¶ÁµÄºº×ÖÊÇÂÒÂë.
2) ¶ÔÓÚҪʵʱ¶ÁÈ¡µÄ, ×ö³ÉÒ³Ãæ»òweb Service·ÅOAÉÏ.
ÏÂÃæÊÇÒ³ÃæʵÏֵIJ¿·Ö´úÂë.
using System.Data.SqlClient; //Á¬½ÓSQL SERVER
using System.Data.OleDb; &n ......
using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Data.SqlClient; ......
ASP.NETÌṩÁËʼþÇý¶¯±à³ÌÄ£ÐÍ£¬Ê¹¿ª·¢Õß¼ò»¯ÁËÓ¦ÓóÌÐòµÄ×ÜÌåÉè¼Æ£¬µ«ÊÇÕâ¸öÒ²Ôì³ÉÁËËü¹ÌÓеÄһЩÎÊÌ⣬ÀýÈ磬ÔÚ´«Í³µÄASPÀÎÒÃÇ¿ÉÒÔͨ¹ýʹÓÃPOST·½·¨ºÜÈÝÒ×µØʵÏÖÒ³Ãæ¼ä´«µÝ±äÁ¿£¬Í¬ÑùµÄÊÂÇ飬ÔÚʹÓÃʼþÇý¶¯±à³ÌÄ£Ð͵ÄASP.NET¾ÍÒªÂ鷳һЩ£¬µ«ÊÇÎÒÃÇÈÔÈ»ÓÐһЩ·½·¨¿ÉÒÔʵÏÖͬÑùµÄ¹¦ÄÜ¡£±ÊÕßÔÚÕâÀォ°üº¬Ê¹ÓÃque ......