A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Inspector "Insert Item" with Redemption



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old August 12th 08, 11:14 PM posted to microsoft.public.outlook.program_vba
LuisE
external usenet poster
 
Posts: 7
Default Inspector "Insert Item" with Redemption

I would like to prompt the "Insert Item" form in Excel and used the selected
item as a variable
All I have is the following code for Outlook that prompts a “Select Folder”
window. I know I have to create the reference to the SafeItem but other than
that I’m stuck.

Set appOutlook = CreateObject("Outlook.Application")
appOutlook.Session.Logon
Set nms = appOutlook.GetNamespace("MAPI")
Set fld = nms.PickFolder


Thanks in advance

Ads
  #2  
Old August 13th 08, 07:15 PM posted to microsoft.public.outlook.program_vba
Eric Legault [MVP - Outlook]
external usenet poster
 
Posts: 830
Default Inspector "Insert Item" with Redemption

There is no way to access the Insert Item dialog through the Outlook Object
Model or any other API, including Redemption You can try the VBA SendKeys
statement, but good luck getting the keystrokes right if it works at all (it
rarely does with modal dialogs).

Your best option is to prompt the user to select the item in a folder, then
access ActiveExplorer.Selection to get the collection of selected items.

--
Eric Legault [MVP - Outlook]
MCDBA, MCTS (Messaging & Collaboration, SharePoint Infrastructure, MOSS 2007
& WSS 3.0 Application Development)
President
Collaborative Innovations
- Try Picture Attachments Wizard 2.0 For Microsoft Outlook -
- Take your SharePoint content offline -
- More info: http://www.collaborativeinnovations.ca -
Blog: http://blogs.officezealot.com/legault


"LuisE" wrote in message
...
I would like to prompt the "Insert Item" form in Excel and used the
selected
item as a variable
All I have is the following code for Outlook that prompts a “Select
Folder”
window. I know I have to create the reference to the SafeItem but other
than
that I’m stuck.

Set appOutlook = CreateObject("Outlook.Application")
appOutlook.Session.Logon
Set nms = appOutlook.GetNamespace("MAPI")
Set fld = nms.PickFolder


Thanks in advance

  #3  
Old August 13th 08, 07:27 PM posted to microsoft.public.outlook.program_vba
LuisE
external usenet poster
 
Posts: 7
Default Inspector "Insert Item" with Redemption

Thanks Eric

Your best option is to prompt the user to select the item in a folder, then
access ActiveExplorer.Selection to get the collection of selected items.


How would I do that?

  #4  
Old August 14th 08, 09:09 PM posted to microsoft.public.outlook.program_vba
Eric Legault [MVP - Outlook]
external usenet poster
 
Posts: 830
Default Inspector "Insert Item" with Redemption

Use this as a reference:

Dim objItems As Outlook.Items
Dim objItem As Outlook.MailItem
Dim intX As Integer

Set objItems = ActiveExplorer.Selection

If Not objItems Is Nothing Then
For intX = 1 To objItems.Count
If objItems.Item(intX).Class = olMail Then
Set objItem = objItems.Item(intX)
'You know have one MailItem object
End If
Next
End If

--
Eric Legault [MVP - Outlook]
MCDBA, MCTS (Messaging & Collaboration, SharePoint Infrastructure, MOSS 2007
& WSS 3.0 Application Development)
President
Collaborative Innovations
- Try Picture Attachments Wizard 2.0 For Microsoft Outlook -
- Take your SharePoint content offline -
- More info: http://www.collaborativeinnovations.ca -
Blog: http://blogs.officezealot.com/legault


"LuisE" wrote in message
...
Thanks Eric

Your best option is to prompt the user to select the item in a folder,
then
access ActiveExplorer.Selection to get the collection of selected items.


How would I do that?

 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Word "SendMail" crashes Outlook Inspector (2007) Dave Taylor[_2_] Add-ins for Outlook 3 May 16th 08 10:32 PM
Opening *.PST file: "Can't open this item. Outlook blocked access to this potentially unsafe item." R2D2 Outlook - General Queries 1 September 16th 07 09:14 AM
Insert "subject" into the "first name" field of contact Luc Outlook - Using Forms 1 July 19th 06 11:31 PM
Do not have "Insert Item" on Paperclip or Insert menu in e-mail Ioparto Outlook - General Queries 7 June 29th 06 09:52 PM
I do not have "Encoding" item in my "View" menu of Outlook 2003? Baher Outlook - Installation 0 June 20th 06 10:35 AM


All times are GMT +1. The time now is 04:53 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright 2004-2025 Outlook Banter.
The comments are property of their posters.