2 simple macros - create task from email and move email to folder

  • Thread starter Thread starter sselden13
  • Start date Start date
S

sselden13

Hello,
I am trying to create 2 simple macros, ideally that I evoke witha
shortcut key.

1. Create a task from an email and attach a copy of the email to the
task. - I don't want the original email moved anywhere. This is to
save having to drag the email to the task button.

2. Move email from inBox to my archive_folder. I want to be able to
hit a keyboard shortcut and move the email out of my inbox to my
"archive" without having to drag it.

I've found a lot of scripts but they all do overly complex things:)

Thanks in advance for any help,
sharon
 
1. Create the task with the CreateItem function. Call its Attachments.Add
function and pass ActiveExplorer.Selection(1) to it - if the e-mail is the
one selected item.

2. See the Move function in the VBA help for a sample.

You can't create shortcut keys in VBA. But you can customize the toolbar:
Right click on it, goto customize, commands, macro, and drag your macro
names onto the toolbar. Then right click on that new button and edit its
name. Use an & character to create an accelerator.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
Keep your Outlook categories organized!
http://www.shareit.com/product.html?productid=300120654&languageid=1
(German: http://www.VBOffice.net/product.html?pub=6)

Am 28 Jan 2007 16:42:35 -0800 schrieb (e-mail address removed):
 
Do #1 with a rule
Rule description:
Apply this rule after the message arrives
with <specify subject words> in the subject
move a copy to the Tasks folder

It won't set a time or any other information, but you would then have
a task with a copy of the email message in it.

#2 can be done by pressing Alt+F followed by Alt+R, and choose a date
and hit enter.
Alternatively, you can put a button on your toolbar to do the first
two keyboard combinations, then choose a date and hit enter.

Right click on the toolbar and pick Customize. On the file menu list,
find Archive, and drag it to the desired spot. With the Customize
window still open, right click the new button, and pick Change Button
Image. I used the little floppy icon with the arrow pointing at the
disk to indicate archiving. Then right click the button again and pick
Default Style.
 
1. Create the task with the CreateItem function. Call its Attachments.Add
function and pass ActiveExplorer.Selection(1) to it - if the e-mail is the
one selected item.

2. See the Move function in the VBA help for a sample.

You can't create shortcut keys in VBA. But you can customize the toolbar:
Right click on it, goto customize, commands, macro, and drag your macro
names onto the toolbar. Then right click on that new button and edit its
name. Use an & character to create an accelerator.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
Keep your Outlook categories organized!
http://www.shareit.com/product.html?productid=300120654&languageid=1
(German:http://www.VBOffice.net/product.html?pub=6)

Am 28 Jan 2007 16:42:35 -0800 schrieb (e-mail address removed):

Thanks for your reply. I should have said, I don't know how to script.
Is there a good tutorial out there for this?
 
You can start with the VBA help, which contains a lot of samples. Open the
object browser and switch from <All Libraries> to Outlook. E.g. find the
Attachments class in the left pane and the Add function in the right one and
then press F1 for help. That works for all mentioned functions.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
Keep your Outlook categories organized!
http://www.shareit.com/product.html?productid=300120654&languageid=1
(German: http://www.VBOffice.net/product.html?pub=6)


Am 3 Feb 2007 13:14:59 -0800 schrieb (e-mail address removed):
 
Back
Top