Lotus Notes 利用Ado防问Access 数据库
来源:互联网 发布:淘宝海报图片男装 编辑:程序博客网 时间:2024/06/11 06:26
//要做办公自动化系统可与我联系QQ:123644449!或访问我的网http://www.csina.com.cn
Sub Initialize
Dim oConn As Variant
Dim oRs As Variant
Dim filePath As String
Dim Index As Integer
Dim vValue As Variant
Dim strName As String
Dim strValue As String
Dim docNew As NotesDocument
Dim count As Long
Dim session As New notessession
Dim db As notesdatabase
Set db=session.currentdatabase
getAccessDBData = True
' Map contact database to physical path
strFileName = "C:/MaBase1.mdb"
'If FileExist( strFileName ) Then
db.DelayUpdates = True
' Create ADO Connection Component to connect with database
Set oConn = CreateObject("ADODB.Connection")
oConn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & strFileName
' Execute a SQL query and store the results within recordset
Set oRs = oConn.Execute("SELECT FirstName,LastName,Company From Contacts")
Do While (Not oRs.eof)
Set docNew = New NotesDocument( db )
count = count + 1
docNew.Form = "Person"
For Index = 0 To (oRs.fields.count-1)
strName = oRs(Index).Name
vValue = oRs(Index).Value
If Isnull(vValue) Then
strValue = ""
Else
strValue = Cstr(vValue)
End If
Call docNew.ReplaceItemValue(strName, strValue)
Next
Call docNew.ComputeWithForm(True,False)
Call docNew.Save(True, False)
If Not session.IsOnServer Then
If (count Mod 100) = 0 Then Print Str(count) & " person documents imported."
End If
oRs.MoveNext
Loop
oRs.Close
oConn.Close
Print Str(count) & " person documents imported."
getAccessDBData = False
Print "File not Found -> " & strFileName
End Sub
- Lotus Notes 利用Ado防问Access 数据库
- 操作Lotus Notes数据库
- NET利用Lotus Notes發送郵件
- VC下利用ADO连接Access数据库
- VC下利用ADO连接Access数据库
- VC下利用ADO连接Access数据库
- MFC利用ADO操作Access数据库
- VC下利用ADO连接Access数据库
- VC下利用ADO连接Access数据库
- VC下利用ADO连接Access数据库
- 利用ADO压缩Access数据库代码
- VC下利用ADO访问Access数据库(Use ADO)(转载)
- VC利用ADO组件来访问数据库的程序设计
- 利用ADO连接ACCESS数据库及其操作数据库的方法
- php利用ADO组件连接access数据库示例
- 利用ADO连接ACCESS数据库,并进行读写操作(MFC)
- 介绍 IBM Lotus Notes access for SAP solutions
- ADO建ACCESS数据库
- VS2005中加载符号
- 关于ATL的rgs注册文件
- C#winform建立一个共用的数据库连接
- 最近查到一个JAVA网址导航,感觉还不错
- 采用ajax的评论系统,回复后再刷新也不见最新的回复
- Lotus Notes 利用Ado防问Access 数据库
- VSExpress版本上WTL开发支持,意见收集
- (最新整理)国内网页设计网站网址大全(转)
- 永不言败的曾道人
- jQuery colspan and rowspan table using cell break
- 解决Apache日志文件ACCESS.LOG日益膨胀的一个办法
- Spreadsheet::ParseExcel::SaveParser 和 Spreadsheet::ParseExcel的内存问题
- 美国青年:整个中国就是一个山寨
- 2009-02-11