|
[x]
Posted via EE Mobile
|
|
| Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again. |
|
|
|
|
Asked by kahvedzic in Lotus Notes
with this code I have content of Lotus mailbox in Listbox, but actually I need to have this data in gridview or table so I can insert this in SQL server database. Every listbox should be one column of gridview/table. This is realy urgent. Thanks
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
88:
89:
90:
91:
92:
93:
94:
95:
96:
97:
98:
99:
|
Imports Domino
Partial Class Default6
Inherits System.Web.UI.Page
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim appNotes As NotesSession
appNotes = New NotesSession
Dim dbNotes As NotesDatabase
appNotes.Initialize()
dbNotes = appNotes.GetDatabase("server", "database")
Dim vwInbox As NotesView
vwInbox = dbNotes.GetView("$Inbox")
Dim docMessage As NotesDocument
On Error Resume Next
With vwInbox
docMessage = .GetLastDocument
Do
Dim v As Object
v = appNotes.Evaluate("@Right(@Left(From; ""/""); ""CN="")", docMessage)
List1.Items.Add(v(0))
'List1.Items.Add(docMessage.GetItemValue("From"))
'List1.Items.Add(Join(docMessage.GetItemValue("From")))
docMessage = .GetPrevDocument(docMessage)
Loop Until docMessage Is Nothing
End With
On Error Resume Next
With vwInbox
docMessage = .GetLastDocument
Do
Dim sbj As Object
sbj = appNotes.Evaluate(("Subject"), docMessage)
List2.Items.Add(sbj(0))
'List2.Items.Add(docMessage.GetItemValue("Subject")(0))
'List2.Items.Add(Join(docMessage.GetItemValue("Subject")(0)))
docMessage = .GetPrevDocument(docMessage)
Loop Until docMessage Is Nothing
End With
On Error Resume Next
With vwInbox
docMessage = .GetLastDocument
Do
'Dim bdy As Object
'bdy = appNotes.Evaluate(("@Text(@Body)", docMessage)
'List3.Items.Add(bdy(0))
List3.Items.Add(docMessage.GetItemValue("Body"))
List3.Items.Add(Join(docMessage.GetItemValue("Body")))
docMessage = .GetPrevDocument(docMessage)
Loop Until docMessage Is Nothing
End With
On Error Resume Next
With vwInbox
docMessage = .GetLastDocument
Do
Dim time As Object
time = appNotes.Evaluate("@Text(DeliveredDate)", docMessage)
List4.Items.Add(time(0))
'List4.Items.Add(docMessage.GetItemValue(("Created")))
'List4.Items.Add(Join(docMessage.GetItemValue(("Created"))))
docMessage = .GetPrevDocument(docMessage)
Loop Until docMessage Is Nothing
End With
On Error Resume Next
With vwInbox
docMessage = .GetLastDocument
Do
Dim attachmentNames As Object
attachmentNames = appNotes.Evaluate("@Implode(@AttachmentNames; "", "")", docMessage)
If attachmentNames <> "" Then
List5.Items.Add(attachmentNames(0))
End If
List5.Items.Add(" ")
docMessage = .GetPrevDocument(docMessage)
Loop Until docMessage Is Nothing
End With
'Dim attachmentNames As Object
'attachmentNames = appNotes.Evaluate("@Implode(@AttachmentNames; "", "")", docMessage)
'List5.Items.Add(attachmentNames(0))
'If attachmentNames = "" Then
' List5.Items.Add(" ")
'Else
' List5.Items.Add(attachmentNames(0))
'End If
'docMessage = .GetPrevDocument(docMessage)
'Dim attachmentNames As Object
'attachmentNames = appNotes.Evaluate("@Implode(@AttachmentNames; "", "")", docMessage)
'List5.Items.Add(attachmentNames(0))
'If attachmentNames <> "" Then
' List5.Items.Add(attachmentNames(0))
'End If
'List5.Items.Add(" ")
'docMessage = .GetPrevDocument(docMessage)
On Error Resume Next
docMessage = Nothing
vwInbox = Nothing
dbNotes = Nothing
appNotes = Nothing
End Sub
End Class
|
20091111-EE-VQP-89 - Hierarchy / EE_QW_3_20080625