|
-
Jan 10th, 2006, 07:45 PM
#1
Thread Starter
Addicted Member
Setting contact to appointment / journal item
How do you set contacts for appointments and journal items?
BeengieHappy.Vaue = (SharksScore > OpponentsScore)
Go Sharks!
-
Jan 10th, 2006, 08:12 PM
#2
Re: Setting contact to appointment / journal item
You need to add a contact as a receipient of the appointment item.
VB Code:
oApptItem.Recipients.Add ("RobDog888")
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Jan 10th, 2006, 08:29 PM
#3
Thread Starter
Addicted Member
Re: Setting contact to appointment / journal item
do I need to create a recipient object?
BTW I am doing this with VBA
I am not sure if I am on the right track. I am confused when it comes to the "recipients" collection and "recipient" object when it relates to a journal item.
I tried to create a recipient object and add it to the journal item, but it did not work. The contacts field was empty when I opened the item in the Outlook UI.
VB Code:
Private Sub CreateJournalItem()
Dim objappitm As Outlook.JournalItem
Dim objRecip As Outlook.Recipient
Set objappitm = Outlook.CreateItem(olJournalItem)
Set objRecip = objappitm.Recipients.Add(cboContact.text)
objappitm.Companies = "Acme"
objappitm.Subject = txtSubject.Text
objappitm.Type = "Phone Call" & " (reveived)"
objappitm.Start = txtDate.Text & " " & txtTime.Text
objappitm.Duration = 30
objappitm.Recipients.Add objRecip
objappitm.Save
End Sub
what's wrong with this code?
thanks for the help
BeengieHappy.Vaue = (SharksScore > OpponentsScore)
Go Sharks!
-
Jan 10th, 2006, 08:39 PM
#4
Thread Starter
Addicted Member
Re: Setting contact to appointment / journal item
I tried what you posted, but there is nothing in the contacts field for any example I try.
BeengieHappy.Vaue = (SharksScore > OpponentsScore)
Go Sharks!
-
Jan 10th, 2006, 08:45 PM
#5
Re: Setting contact to appointment / journal item
For the ContactItem you also need to do a .Recipients.ResolveAll
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Jan 10th, 2006, 08:51 PM
#6
Thread Starter
Addicted Member
Re: Setting contact to appointment / journal item
BeengieHappy.Vaue = (SharksScore > OpponentsScore)
Go Sharks!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|