Dear friends,
does anyone know of a way to import tasks to assign to others from Excel 2007 to Outlook 2007? I want to do away with a sequential checklist that is hand delivered to staff members and, instead, setup a spreadsheet that I can use that even sets the send date of the task.
Thanks in advance,
Mike
Learn to Serve Others. Kindness is far better than the alternative.
Mike, similar question just a couple of days ago - might help ?
http://www.excelforum.com/excel-prog...rom-excel.html
EDIT: in retrospect, are you looking to run the code from OL (as implied by the forum in which this was posted - did not spot that) - if so can you provide a sample XL file so we can see your proposed layout etc so as to be able to put some code together re: retrieval ?
Last edited by DonkeyOte; 08-03-2009 at 04:13 AM.
My Recommended Reading:
Volatility
Sumproduct & Arrays
Pivot Intro
Email from XL - VBA & Outlook VBA
Function Dictionary & Function Translations
Dynamic Named Ranges
That link helped greatly. Thanks for it. I will have to program the code to produce as many tasks as there are columns of data, since each checklist contains 15-20 tasks, not just one.
The code that you reference did not provide any help about assigning the tasts to others. Is there any way that code can do this if the e-mail address of the Outlook 2007 recipient is known?
Thank you again,
Mike
Learn to Serve Others. Kindness is far better than the alternative.
Iterating should not be simple enough but as I say we would need to know your layout to give a tailored example... re: your point on distribution, you would modify along the lines of:
Again, to reiterate, the above is XL VBA code controlling OL rather than OL code controlling XL... if that's your intention let me know as we need to move the thread to the XL Programming Forum.Code:Public Sub Example() Dim OLApp As Outlook.Application Dim OLTk As Outlook.TaskItem Set OLApp = New Outlook.Application Set OLTk = OLApp.CreateItem(olTaskItem) With OLTk .Subject = Cells(1, "A") .StartDate = Cells(2, "A") .DueDate = Cells(2, "A") + 1 .ReminderTime = .StartDate - 1 .Body = "This is a Task" .Recipients.Add "someone@somewhere.com" .Assign .Save .Send End With Set OLTk = Nothing Set OLApp = Nothing End Sub
My Recommended Reading:
Volatility
Sumproduct & Arrays
Pivot Intro
Email from XL - VBA & Outlook VBA
Function Dictionary & Function Translations
Dynamic Named Ranges
Thank you for the post. Yes, this is Excel modifying Outlook. It would have been best if I had posted to the Excel area. Sorry about that. Actually, in all the time I have used this great forum I never know anything existed about Outlook.
You stated " Iterating should not be simple enough but as I say we would need to know your layout to give a tailored example."
What I would like to have is one column for each person that I need to assign a task. The first three rows, however, would have data (like page title) on it, so we would start in row 4 and below of each column for each task to be assigned.
Does that help?
Mike
Learn to Serve Others. Kindness is far better than the alternative.
Is the task itself (ie subject, date, reminder etc) the same for all recipients as listed in A4 onwards ?
(thread moved to Excel Programming as discussed)
My Recommended Reading:
Volatility
Sumproduct & Arrays
Pivot Intro
Email from XL - VBA & Outlook VBA
Function Dictionary & Function Translations
Dynamic Named Ranges
The subject and the recipient are different in all cases. That is one reason that I was wanting to use different columns to take care of that.
Thanks,
Mike
Learn to Serve Others. Kindness is far better than the alternative.
OK well given you're not going to provide a sample I will...
(note: attached is 2007 macro enabled format (.xlsm) and will contain refernence to Outlook 12.0 Object Library)
I'm not running on an Exchange but for an Exchange recipient you should find you can use their mailbox name rather than full mail address (you may need to let the code resolve it first), for external recipients full address is likely to be required ... my knowledge of OL protocol is limited (at best).
In the example I commented out .Send as obviously the mail addresses are not real ... obviously you should alter your own code according to your own requirements, if you need more specific advice relative to your own file / setup we will need to see it... (you can of course dummy values such that confidentiality is maintained)
My Recommended Reading:
Volatility
Sumproduct & Arrays
Pivot Intro
Email from XL - VBA & Outlook VBA
Function Dictionary & Function Translations
Dynamic Named Ranges
Dear DonkeyOte,
This is wonderful! It does exactly what I need done. We have an exchange server, but some of our people are out of the office with laptops and don't VPN into the system. I like the layout of putting the date in rows rather than columns.
You have helped a great deal! Thank you very much!
Mike
Learn to Serve Others. Kindness is far better than the alternative.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks