Domino 9 und frühere Versionen > ND6: Entwicklung
Zugriff auf Notes Attachments von außen?
pjsb:
GELÖST
--- Code: ---Function getNotes_data(server As String, path As String)
Dim DOMSession As New NotesSession
Dim DOMDB As NotesDatabase
Dim DOMView As NotesView
Dim DOMDoc As NotesDocument
Dim DOMFile As NotesEmbeddedObject
Dim i, ende As Integer
Dim result()
DOMSession.Initialize
Set DOMDB = DOMSession.GetDatabase(server, path)
Set DOMView = DOMDB.GetView("viewTemplatesByNameDE")
Set DOMDoc = DOMView.GetFirstDocument
i = 0
ende = DOMView.EntryCount
ReDim Preserve result(0 To ende, 0 To 10)
Do Until (DOMDoc Is Nothing)
result(i, 0) = i
result(i, 1) = DOMDoc.GetItemValue("sSubject")(0)
result(i, 2) = DOMDoc.GetItemValue("sDocType")(0)
result(i, 3) = DOMDoc.GetItemValue("sLanguage")(0)
result(i, 4) = DOMDoc.GetItemValue("sCountry")(0)
result(i, 5) = DOMDoc.GetItemValue("sLocation")(0)
result(i, 6) = DOMDoc.GetItemValue("sDepartment")(0)
result(i, 7) = DOMDoc.GetItemValue("sAttachmentName")(0)
result(i, 8) = DOMDoc.GetItemValue("sRemark")(0)
result(i, 9) = DOMDoc.GetItemValue("sStandardTemplate")(0)
Set DOMFile = DOMDoc.GetAttachment(result(i, 7))
DOMFile.ExtractFile "R:\Temp\Test\" & result(i, 7)
Set DOMDoc = DOMView.GetNextDocument(DOMDoc)
i = i + 1
Loop
getNotes_data = result()
End Function
--- Ende Code ---
Navigation
[0] Themen-Index
[*] Vorherige Sete
Zur normalen Ansicht wechseln