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

ASP.NETµÄACCESSÊý¾Ý¿â²Ù×÷Àà

//private string datapatch = ConfigurationSettings.AppSettings["acessconn"];//Êý¾Ý¿âµØÖ· 
private string datapatch = "db/global.asa";//Êý¾Ý¿âµØÖ· 
/// 
/// È¡µÃdataset 
// 
/// ²éѯÓï¾ä 
/// 
public DataSet GetDataSet(string Commandtext) 

string strConnection = "Provider=Microsoft.Jet.OLEDB.4.0; " + 
"Data Source=" + Server.MapPath(datapatch); 
string strCommandText = Commandtext; 
OleDbConnection myConnection = new OleDbConnection(strConnection); 
myConnection.Open(); 
OleDbDataAdapter myAdpater = new OleDbDataAdapter(strCommandText,myConnection); 
OleDbCommandBuilder myBuilder = new OleDbCommandBuilder(myAdpater); 
DataSet myDataset = new DataSet(); 
myAdpater.Fill(myDataset); 
myConnection.Close(); 
return myDataset; 

/// 
/// È¡µÃ±í 
/// 
/// ²éѯÓï¾ä 
/// 
public DataTable GetDataTable(string Commandtext) 

string strConnection = "Provider=Microsoft.Jet.OLEDB.4.0; " + 
"Data Source=" + Server.MapPath(datapatch); 
string strCommandText =Commandtext; 
OleDbConnection myConnection = new OleDbConnection(strConnection); 
myConnection.Open(); 
OleDbDataAdapter myAdpater = new OleDbDataAdapter(strCommandText,myConnection); 
OleDbCommandBuilder myBuilder = new OleDbCommandBuilder(myAdpater); 
DataSet myDataset = new DataSet(); 
myAdpater.Fill(myDataset); 
DataTable mytable = myDataset.Tables[0]; 
myConnection.Close(); 
return mytable; 

/// 
/// È¡µÃijÐеÄijÁеÄÖµ 
/// 
/// ÁеÄÃû³Æ 
/// ËùÊô±íÃû 
/// ±íµÄÖ÷¼ü 
/// ÁÐËùÊôµÄÖ÷¼üÖµ 
/// 
public string GetDataColum(string strColumnName,string strTableName,string strColumnkey,string strColumnValue) 

string strConnection = "Provider=Microsoft.Jet.OLEDB.4.0; " +


Ïà¹ØÎĵµ£º

ΪaccessÊý¾Ý¿â´´½¨ÓµÓв»Í¬·ÃÎÊȨÏÞµÄÓû§

      JavaÅàѵ¿Î³ÌÖ®Êý¾Ý¿â¼¼Êõѧϰ
      ¿´µ½ºÜ¶à³õѧÕß·´¸´ÎÊÕâ¸öÎÊÌ⣬дÁËÒ»¸öºÜ¼òµ¥µÄÒ»¸ö½Å±¾£¬ÓÃÓÚ×Ô¶¯ÉèÖû·¾³±äÁ¿¡£°Ñ´úÂ뿽±´£¬Áí´æΪjavaEnv.bat¡£°²×°ÍêJava 2 SDKÖ®ºó£¬¿ªÒ»¸öÃüÁîÐд°¿Ú,ÊäÈëjavaEnv java2SDKDir(java2SDKDirÊÇÄãµÄjavaµÄ°²×°Ä¿Â¼£¬²»´ ......

SQL2005ºÍ(Excel |access)Ö®¼äµÄÊý¾Ýµ¼Èëµ¼³ö


Sql´úÂë
--²ÉÓÃSQLÓï¾äʵÏÖsql2005ºÍExcel Êý¾ÝÖ®¼äµÄÊý¾Ýµ¼Èëµ¼³ö£¬ÔÚÍøÉÏÕÒÀ´Ò»--Ï£¬ÊµÏÖ·½·¨ÊÇÕâÑùµÄ£º    
  
  
--Excel---->SQL2005  µ¼È룺    
  
  
select * into useinfo from O ......

Ô¶³ÌÁ¬½ÓaccessÊý¾Ý¿âµÄ¼¸¸ö·½·¨£º

ʹÓÃÁËTCP/IP£¬ADO¼°XML£¨ÐèÒª°²×°Microsoft XML 4.0¡££©¡£·Ö·þÎñÆ÷ºÍ¿Í»§¶ËÁ½²¿·Ö£¬·þÎñÆ÷¿ÉÒÔ¶àÓû§Í¬Ê±Á¬½Ó¡£Ô¶³ÌÁ¬½ÓAccessÊý¾Ý¿âÓкܶ෽·¨£¬ÎÒÒÔÇ°ÒѾ­±È½Ï¾ßÌåµÄ»Ø´ð¹ý£¨¼ûÏÂÃæËùÁеÄ5ÖÖ·½·¨£©£¬ÎÒÏÖÔÚÕâ¸öÀý×ÓÊôÓÚÆäÖеĵڣ³ÖÖ·½·¨£¨²»ÐèҪʹÓÃRDS»òWeb·þÎñÆ÷£©¡£
Ô¶³ÌÁ¬½ÓaccessÊý¾Ý¿âµÄ¼¸¸ö·½·¨£º
£±£®½¨Á¢VPN ......

PBÖÐÁ¬½ÓAccessÊý¾Ý¿âµÄÈýÖÖ·½·¨

PBÖÐÁ¬½ÓAccessÊý¾Ý¿âµÄÈýÖÖ·½·¨
·½Ê½Ò»£º
SQLCA.DBMS = "ODBC"
SQLCA.AutoCommit = False
SQLCA.DBParm = "ConnectString='driver=Microsoft Access Driver (*.mdb);DBQ=c:\foodmart.mdb'"
CONNECT;
IF SQLCA.SQLCode <> 0 THEN
MessageBo ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ