远程连接access数据库的几个方法:
使用了TCP/IP,ADO及XML(需要安装Microsoft XML 4.0。)。分服务器和客户端两部分,服务器可以多用户同时连接。远程连接Access数据库有很多方法,我以前已经比较具体的回答过(见下面所列的5种方法),我现在这个例子属于其中的第3种方法(不需要使用RDS或Web服务器)。
远程连接access数据库的几个方法:
1.建立VPN,这样你的电脑和主机的连接就与局域网无异,然后把服务器中mdb文件所在的Folder共享即可。ADO连接如下:oConn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=““ServerName“DatabaseFolder“Database.mdb;Jet OLEDB:Database Password=databasepw;Persist Security Info=False"
2.把Database放在Web Server上,使ADO或RDO通过RDS(Remote Data Service)及IIS来实现:
假如服务器像上面Jave大侠说那样设置了ODBC DSN的话:
oConn.Open "Provider=MS Remote;" _
"Remote Server=http://myServerName;" _
"Remote Provider=MSDASQL;" _
"DSN=AdvWorks;" _
"Uid=myUsername;" _
"Pwd=myPassword"
假如设置的是OLE DB Provider 的话:
oConn.Open "Provider=MS Remote;" _
"Remote Server=http://myServerName;" _
"Remote Provider=Microsoft.Jet.OLEDB.4.0;" _
"Data Source=c:“somepath“mydb.mdb", _
"admin", ""
3.自己编写服务器程序,通过TCP/IP,传递Recordset。
4.使用第三方控件,如:ADO Anywhere或UDAParts RDB等。具体查看
http://www.adoanywhere.com
http://www.udaparts.com/
5.使用XMLHTTP
提醒: 远程连接SQL Server的方法:
ConnStr = "Provider=SQLOLEDB.1;Network Library=DBMSSOCN;Persist Security Info=True;User ID=UserName;Password=Password;Initial Catalog=远程数据库名;Data Source=203.129.92.1"
相关文档:
一、创建一张空表:
Sql="Create TABLE [表名]"
二、创建一张有字段的表:
Sql="Create TABLE [表名]([字段名1] MEMO NOT NULL, [字段名2] MEMO, [字段名3] COUNTER NOT NULL, [字段名4] DATETIME, [字段名5] TEXT(200), [字段名6] TEXT(200))
字段类型:
2 : "SmallInt", // 整型
3 : "Int", ......
转帖:http://www.stealthcopter.com/blog/2010/01/android-requesting-root-access-in-your-app/
This snippet shows how root access can be requested inside an application in order to write a file into a place we do not have permission to access usually. Requesting root access will only work if your phon ......
<%Dim connstrconnstr="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath("Stu.mdb")
Set bb = Server.CreateObject("ADODB.Connection")
bb.Open connstr%>
<html>
<head>
<meta http-equiv="content-Language" content="zh-cn" />
<meta http-equiv="Content-Type ......
asp 中文乱码,asp access 乱码,asp 刷新后乱码,asp utf 8乱码,ajax 乱码 asp,asp 汉字乱码,asp乱码怎么办
用utf-8编码用在新的网站上,不想问题还真多,所以找了些文章,帖子,看了看,等下有用的就贴下面了。
今天,我开始把 CODEPAGE="936" 改成 CODEPAGE="65001"
把charset=gb2312改成 charset=utf-8
可是还是乱码 ......