C#ÖÐÁ¬½Ó¼°²éѯAccess³öÏÖµÄÎÊÌâ
´óÏÀÃÇ£º
ÕâÊÇÎÒÁ¬½ÓÊý¾Ý¿âµÄ´úÂë
string strPath = Application.StartupPath + "\\Database.accdb";
string ConStr = "provider=Microsoft.jet.oledb.4.0;Data source=" + strPath;
OleDbConnection Olecon = new OleDbConnection(ConStr);
Olecon.Open();
string sql = "Select * from ѧÉúÐÅÏ¢ where ѧºÅ= '" + textBox1.Text.Trim() + "' ";
OleDbDataAdapter da = new OleDbDataAdapter(sql, Olecon);
DataSet ds = new DataSet();
da.Fill(ds, "ѧÉúÐÅÏ¢");
this.dataGridView1.DataSource = ds.Tables[0];
±¨´í£º
{"ÕÒ²»µ½Îļþ 'E:\\Êý¾Ý¿â»ù±¾²Ù×÷\\Êý¾Ý¿â»ù±¾²Ù×÷\\bin\\Debug\\Database.accdb'¡£"}
ʲôÔÒòÄØ¡¡
C# code:
@'E:\Êý¾Ý¿â»ù±¾²Ù×÷\Êý¾Ý¿â»ù±¾²Ù×÷\bin\Debug\Database.accdb'
??
ÄDz»ÊÇ˵ÁËÂð ÕÒ²»µ½Îļþ ÄãÄǸö·¾¶ÏÂÓÐÕâ¸öÎļþÂð£¿
C# code
Code highlighting produced by
Ïà¹ØÎÊ´ð£º
ÄÄÀï³ö´íÁË£¬Êä³öÕâÑùµÄ½á¹û£¿£¿
<%@ Page Language="VB" AutoEventWireup="false" aspcompat="true" CodeFile="Default.aspx.vb" Inherits="_Default" %&g ......
Êý¾Ý¿âÁ¬½ÓÌáʾÈçϱ¨´í£¬¿´µÄ³öÀ´ÊÇÒ³ÃæÓëÊý¾Ý¿âÁ¬½ÓµÄÎÊÌ⣬ÏÖÔÚÎÒµÄÊÇÏà¶ÔÁ¬½Ó¡£
ÒªÔõô½«Æä¸Ã³É¾ø¶ÔÁ¬½ÓÄØ£¿ÎÒµÄÊý¾Ý¿âÎļþ·¾¶ÔÚ£º
D:\web\db
»¹ÊÇÒªÏÈлл´óÈËÃǰïÖúС°×²ËÎÒ
Microsoft O ......
Çë¸÷λָµãÏ£º³ÌÐò´úÂëÈçÏÂmingchen = "C:\Îļþ·¾¶\"
cat = New ADOX.Catalog
cat.Create("Provider=Microsoft.Jet.OLEDB.4.0;" & "Data Source=" & min ......
win2000ϵͳADOÁ¬½ÓACCESSÊý¾Ý¿â±ØÐèÒª½øÈë×ÀÃæÂð?
ÎÒÓÐÒ»¸ö×°ÁËwin2000-SP4µÄ»ú×Ó,ÒÑ×°ÁËMDAC 2.8 ,дÁ˸öwindows·þÎñ³ÌÐòÊÇÓÃADO²Ù×÷ACCESSÊý¾Ý¿âµÄ,Ææ¹ÖµÄÊÇ´ò¿ªÊý¾Ý¿âÎļþʱ,±ØÐèÒªµÇ¼µ½×ÀÃæ²ÅÄÜÕý³£´ò¿ ......