PDA

View Full Version : در مورد امکان استفاده از outlook در این فرم



linux
سه شنبه 29 مهر 1382, 23:53 عصر
می‌خواستم ببینم میشه با اوت لوک به این فرم وصل شد مثل بعضی از این نیوزهایی که هستند؟

ایران ویج
چهارشنبه 30 مهر 1382, 10:20 صبح
من خودم کار نکردم ولی این کد واسه استفاده از آوت لوک مربوط به آفیس هستش که ایمیلهایی که ارسال شده رو نمایش میده ولی قبلش باید آفیس رو بخصوص آوت لوک روسیستمت نصب باشه تا کامپوننت های مربوطه رو بشه به ویپوال بیسیک اضافه کرد


Dim oApp As New Outlook.Application
Dim oExp As Outlook.Explorer
Dim oSel As Outlook.Selection ' You need a selection object for getting the selection.
Dim oItem As Object ' You don't know the type yet.

Set oExp = oApp.ActiveExplorer ' Get the ActiveExplorer.
Set oSel = oExp.Selection ' Get the selection.

For i = 1 To oSel.Count ' Loop through all the currently .selected items
Set oItem = oSel.Item(i) ' Get a selected item.
DisplayInfo oItem ' Display information about it.
Next i

ایران ویج
چهارشنبه 30 مهر 1382, 10:22 صبح
من خودم کار نکردم ولی این کد واسه استفاده از آوت لوک مربوط به آفیس هستش که ایمیلهایی که ارسال شده رو نمایش میده ولی قبلش باید آفیس رو بخصوص آوت لوک روسیستمت نصب باشه تا کامپوننت های مربوطه رو بشه به ویپوال بیسیک اضافه کرد



Dim oApp As New Outlook.Application
Dim oExp As Outlook.Explorer
Dim oSel As Outlook.Selection ' You need a selection object for getting the selection.
Dim oItem As Object ' You don't know the type yet.

Set oExp = oApp.ActiveExplorer ' Get the ActiveExplorer.
Set oSel = oExp.Selection ' Get the selection.

For i = 1 To oSel.Count ' Loop through all the currently .selected items
Set oItem = oSel.Item(i) ' Get a selected item.
DisplayInfo oItem ' Display information about it.
Next i

'-----------------------------------------------
Sub DisplayInfo(oItem As Object)
Dim oMailItem As Outlook.MailItem

strMessageClass = oItem.MessageClass

If (strMessageClass = "IPM.Note") Then ' Mail Entry.
Set oMailItem = oItem
MsgBox oMailItem.Subject
MsgBox oMailItem.SenderName
End If
End Sub

linux
چهارشنبه 30 مهر 1382, 18:13 عصر
منظورم بیشتر این بود که بصورت افلاین بشه به سوالات جواب داد بعد که آنلاین شدی
بفرستی