Push a single contact through to excel

N

nickypatterson

I am new to macros but see that they will greatly help to run my small
business.

I have been trying to find some code which suits my requirement of pushing
signgular fields from a contact into a pre-prepared excel book which is
loaded with the next stage of macro-powered automation.

I recieve enquiries both via email and by phone. I use my blackberry to
save phone enquiries to address book and Anagram for Blackberry to capture
the required contact data from our email enquiry form. Both are then
synchronised with my Outlook contacts.

Either from the point of creation, or through use of a macro button, I want
to automatically add a new contact's information into a prepared SOURCE
DATA.xls which at the moment automates the task and appointment schedule for
that contact.

I do not want to import or export all of my outlook contacts - I simply want
to export 1 contact as and when they are added to my address book (under the
category of "client").

From this SOURCE DATA.xls (which is then automatically saved into it's own
folder and file eg Clients/MRS_P/MRS_P_SOURCE_DATA.xls) I want to export the
info into various quotations, forms etc for printing and use by my staff.
These 2 processes I have managed thus far satisfactorily but the initial
action of pushing a contact through to my 'source data' book seems very
difficult to find any information on.

The info I need to push would be Full Name (first and surname - from which I
derive a reference code necessry for filing etc) Their full address, phone
number,
email address, and notes.

So is this possible?

I have some other ideas for simplifying alot of our admin work - but I
doubt that they are original ideas so there must be some precedence out
there. I know what I want to do but not how to do it.

Any help greatly appreciated.
 
E

Eric Legault [MVP - Outlook]

Sure, all of this is definitely possible.

For starters, there's a code sample here that can get you started:
http://www.helenfeddema.com/CodeSamples.htm#Code41

Basically, you need to familiarize yourself with both the Outlook and Excel
Object Models. At the lowest level, you need to get a ContactItem object,
usually via ActiveInspector.CurrentItem - which represents the active, opened
e-mail.

All data in the ContactItem object is exposed via numerous properties that
you can read to push into the Excel file.

You can find additional assistance and code samples at
http://www.outlookcode.com, and feel free to follow up with me for more
guidance.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top