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

ACCESSÀïÃæ´´½¨´ø²ÎÊýµÄ´æ´¢¹ý³Ì

ÐèҪעÒâµÄÊÇpage_loadÀïÃæµÄ´´½¨´æ´¢¹ý³ÌÖ»ÄÜÖ´ÐÐÒ»´Î£¬Èç¹ûµÚ¶þ´Î»¹Òª´´½¨Í¬ÃûµÄ»°»áÌáʾ´íÎóÐÅÏ¢“´æ´¢¹ý³ÌÒѾ­´æÔÚ¡£”£¬Æäʵ¼Ó¸öÅжϾÍÐÐÁË¡£ÀÁµÃ¼ÓÁË£¬Ö»ÊÇÓÃÀ´ÊÔÑéһϡ£
µ÷ÊÔ»·¾³ ASP.NET 2.0£¨±àÒ빤¾ßVS2008£©£¬´úÂëC#£¬access°æ±¾2003
protected void Page_Load(object sender, EventArgs e)
{
OleDbConnection oledb = new OleDbConnection();
oledb.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\\asp99cms.mdb;Jet OLEDB:Database Password=";
oledb.Open();
if (oledb.State == ConnectionState.Open)
{
string str = "Create proc pr_test(@uid int) As select * from Download where [ID]=@uid";
OleDbCommand olecom = new OleDbCommand();
olecom.CommandText = str;
olecom.Connection = oledb;
olecom.ExecuteNonQuery();
oledb.Dispose();
}
oledb.Close();
oledb.Dispose();
}
protected void Button2_Click(object sender, EventArgs e)
{
OleDbConnection oledb = new OleDbConnection();
oledb.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\\asp99cms.mdb;Jet OLEDB:Database Password=";
oledb.Open();
if (oledb.State == ConnectionState.Open)
{
OleDbCommand olecom = new OleDbCommand("pr_test",oledb);
olecom.CommandType = CommandType.StoredProcedure;
olecom.Parameters.Add(new OleDbParameter("@uid",OleDbType.Integer)).Value=TextBox1.Text;
olecom.Connection = oledb;
OleDbDataReader oledr;
oledr=olecom.ExecuteReader();
oledr.Read();
if (oledr.HasRows)
{
Response.Write("´æ´¢¹ý³ÌÖ´Ðгɹ¦");
}
oledr.Close();
oledr.Dispose();
oledb.Dispose();
}
oledb.Close();
oledb.Dispose();
}


Ïà¹ØÎĵµ£º

aspÍøÕ¾ ACCESSתSQL SERVER 2000

»¨ÁËÁ½¸öÍíÉϰïÅóÓѽ«Ò»¸öasp¿ª·¢µÄÍøÕ¾´ÓACCESSÊý¾Ý¿âתÏòSQL SERVER 2000. ÍøÉϲéÁËЩ×ÊÁÏ£¬¼ÓÉÏ×Ô¼ºµÄ¾­Àú£¬×ܽ᣺
1¡¢Ê×ÏÈ¿´asp µÄ³ÌÐòÖÐÊÇ·ñÓÐ on error resume next; Èç¹ûÓÐ,ÏÈ×¢Ê͵ô¡£·ñÔòºÜ¶à´íÎóÎÞ·¨±©Â¶³öÀ´
2¡¢´´½¨SQL SERVER Êý¾Ý±í¡£ ʹÓÃSQL SERVER 2000×Ô´øµÄÊý¾Ýµ¼ÈëÏòµ¼£¬½«ACCESSÊý¾Ý¿âÖеıí½á¹¹£¬ÒÔ¼ ......

OPENDATASOURCE ´ò¿ªexcel¡¢access¡¢qsl

OPENDATASOURCE ´ò¿ªexcel¡¢access¡¢qsl
use test
insert into OPENDATASOURCE('SQLOLEDB', 'Data Source=192.168.2.200;User ID=sa;Password=110').test.dbo.adf--´ò¿ªÔ¶³ÌÊý¾Ý¿â
select * from OpenRowSet('Microsoft.Jet.OLEDB.4.0', 'Excel 8.0;HDR=Yes;IMEX=1;Database=c:\2003.xls', [kg$])
 --²éѯԶ³ÌÊý¾Ý ......

DELPHIÖвÙ×÷ACCESSÊý¾Ý¿â

DELPHIÖвÙ×÷ACCESSÊý¾Ý¿â(½¨Á¢.mdbÎļþ,ѹËõÊý¾Ý¿â)

ÒÔÏ´úÂëÔÚWIN2K,D6,MDAC2.6ϲâÊÔͨ¹ý,

±àÒëºÃµÄ³ÌÐòÔÚWIN98µÚ¶þ°æÎÞACCESS»·¾³ÏÂÔËÐгɹ¦.







//ÉùÃ÷Á¬½Ó×Ö·û´®

Const

SConnectionString      
= 'Provider=M ......

Failed to access IIS metabase

Failed to access IIS metabase.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Web.Hosting.HostingEnvironmentException: ......

access ÖеÄÎı¾µ½Êý¾ÝÀàÐ͵Äת»»

ÓÃCdbl()ÊÔÊÔ
CDbl(str)   -->   Ë«¾«¶È
CInt(str)   -->   ÕûÐÍ
CLng(str)   -->   ³¤ÕûÐÍ
CSng(str)   -->   µ¥¾«¶È
CDate(str)   -->   ÈÕÆÚÐÍ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ