Results 1 to 2 of 2
  1. #1
    5 Star Lounger
    Join Date
    Aug 2001
    Location
    NY, NY, USA
    Posts
    654
    Thanks
    10
    Thanked 0 Times in 0 Posts

    Outlook automated import into contacts (Outlook XP)

    Can I automate the import of a say b.csv file into contacts by creating a visual basic or macro routine and assign it to a button on the toolbar.
    Ideally it would be nice to also have excel open the b.csv file and save it as a csv file since contacts does not import a routine dos csv. file. I dump a medical list of patients every week into the b.csv file overwriting it. Also it would need to delete all current contacts and import the new contacts. into outlook
    Jerome

  2. #2
    5 Star Lounger
    Join Date
    Oct 2002
    Location
    Wellington, Wellington, New Zealand
    Posts
    621
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Outlook automated import into contacts (Outlook XP)

    Jerome
    I'm a little confused with your quote "since contacts does not import a routine dos csv. file"
    Yes it does under File > Import and Export > Import from another Program or File > Comma Separated Values (DOS)
    It helps to have a header row which names each field

    To return to your question the quick answer is Yes you can write VBA to import a CSV

    Outlook does not provide access to the import wizard so you cannot mimic the manual process.
    However, it is not too hard to upload a standard .csv file the hard way. <img src=/S/compute.gif border=0 alt=compute width=40 height=20> I haven't done it (yet) but the concept is simple enough and I'll happily have a play if you have a need. If your csv is always in a standard format it will be easy enough to create a contact item from each line. Can you either post or mail me a sample of a record named by field type e.g. name,email,address1,address2 or whatever and provide a little detail on how fixed the directory and filename for the csv are - e.g. can the macro just open a file from a fixed place or do you want interaction?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •