473,788 Members | 2,744 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Display outlook 'Select Names' (any VB gurus here?)

2 New Member
Hi, i have been having trouble how to open the 'To' Contacts list(Cc or To) (address book) of a mail message in outlook using vb.net from where the user would be able to select an email address and would be pulled and stored in our database for later use in the application. I have searched on the internet for it and all that i would find is code that would open up the contacts list, which i dont need. i have been having trouble with finding this code. other than that i have this code which actually opens it up, but im not able to store the selected item. if someone could either let me know what to do with the code i have, to get the selected item or show me a different way to come across this problem.
Thank You.

This is the code i have:

Public Shared Function Test1() As String
Dim objSession As Object
''Dim objSession As
Dim objRecipients As Object
Dim strEntryID As String
Dim strStoreID As String
Dim ss As Outlook.Recipie nt


objSession = CreateObject("M API.Session")



objSession.Logo n("", "", False, False)
''objRecipients = objSession.addr essbook( _
'' Title:="Select Contact Person", _
'' oneaddress:=Tru e, _
'' Forceresolution :=True, _
'' reciplists:=0)

objRecipients = objSession.addr essbook



Try
'MsgBox(objReci pients(1), vbOKOnly, "Selected Name")
'' MsgBox(objRecip ients, MsgBoxStyle.OKO nly, "Selected Name")

ss = objRecipients(1 )
Catch e As Exception
MessageBox.Show (e.Message)
End Try

objSession.Logo ff()
objSession = Nothing
objRecipients = Nothing


End Function
Aug 22 '07 #1
0 1257

Sign in to post your reply or Sign up for a free account.

Similar topics

13
1347
by: DavidS | last post by:
I have HTML web page with <asp:Image id=img_L runat=server ImageAlign=Top Visible=True Width=y Height=x></asp:Image>. For some images, less than 128K I can view image. Other image files > 128K, image is not viewable - comes up with X in picture box. Is there size restriction. How can I remove this - or how can I show images > 128K in web page. NOTE: x & y in asp:Image spec are distinct values - say 128 x 128 or 64 x 64 image sizes
0
1152
by: brbxx99x | last post by:
Hi, I'm just wondering how I can display the outlook address list (the screen that is displayed when one clicks on either the TO, CC or BCC buttons) and retrieve the email addresses that the user selects once that screen is closed. I'd rather not code the same functionality but would rather display the 'standard' outlook screen and obtain the data from that. Is this possible? Any information would greatly be appreciated. Thanks in...
2
1802
by: Arnold | last post by:
Greetings Gurus, In a report showing the names of students and their progress, I am getting an error in the name field (Name: #Error). The report gets its data from an unbound form containing two unbound textboxes, "txtStartDate" and "txtEndDate," and a multi-select listbox, "listName." I think the error occurs when there is no correct combination of data--for instance, no records for John Doe entered during this past week.
3
4379
by: Jeff Waskiewicz | last post by:
Hello, I think the subject says it all I am trying to return a list of domain names to later display in a combobox. I found a number of VB6 samples that show how to do this using the WNetOpenEnum and WNetEnumResource API calls. I have modified the code to work in VB 2003 but I keep getting a 487 - ERROR_INVALID_ADDRESS error. My envioronment is W2K with a W2003 DC. So I have 2 questions: 1) Is this the best way to do this in .NET?...
5
1799
by: raymonj | last post by:
Hi, Is it possible to display the Outlook recipient window from Vb.Net and receive the email selection the user has chosen when the window is closed ? Thanks folks.
1
1966
by: Soumya v s | last post by:
i wants to display all table names in the combo box with php and mysql
5
4668
by: =?ISO-8859-1?Q?Tom=E1s_=D3_h=C9ilidhe?= | last post by:
On Jun 3, 3:23 am, Jesse Ziser <d...@spam.diewrote: The relevant paragraph from the Standard is: ---- Begin Quote ---- The type declared is va_list which is an object type suitable for holding information needed by the macros
0
9498
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10373
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10118
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9969
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8995
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5538
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4074
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3677
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2897
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.