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

export figure from Outlook msg to Excel



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old April 21st 07, 07:29 AM posted to microsoft.public.outlook.program_vba
Max Bialystock
external usenet poster
 
Posts: 3
Default export figure from Outlook msg to Excel

I'd like to be able to use a macro in Outlook 2003 to find "Total sales" in
the current mail item and export the result to A1 in an Excel spreadsheet.

I think it's possible, but I don't know how to do it.

The following day I would run the macro again and export the result to A2 in
the same spreadsheet.

If anyone can assist at all, I'll be very grateful indeed.


Ads
  #2  
Old April 25th 07, 05:59 AM posted to microsoft.public.outlook.program_vba
Michael Bauer [MVP - Outlook]
external usenet poster
 
Posts: 1,885
Default export figure from Outlook msg to Excel



You can search strings in the mail with the Instr function, and extract them
e.g. with Left, Right, and Mid.

Add a reference to Excel to your Outlook project via Tools/References. This
opens a workbook:

Dim xl As Excel.Application
dim wb as Excel.Workbook
Dim ws as Excel.Worksheet
Dim rn as Excel.Range

Set xl=new Excel.Application
Set wb=xl.Workbooks.Open("file")
Set ws=wb.sheets(1)
Set rn=ws.Range("A1")

rn.Value = "hello"


--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
Quick-Cats - Categorize Outlook data:
http://www.vboffice.net/product.html?id=2006063&cmd=detail&lang=en&pub=6

Am Sat, 21 Apr 2007 16:29:14 +1000 schrieb Max Bialystock:

I'd like to be able to use a macro in Outlook 2003 to find "Total sales"

in
the current mail item and export the result to A1 in an Excel spreadsheet.

I think it's possible, but I don't know how to do it.

The following day I would run the macro again and export the result to A2

in
the same spreadsheet.

If anyone can assist at all, I'll be very grateful indeed.

 




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
How to export Outlook Calendar to Excel Hally Outlook - Calandaring 1 April 5th 07 04:49 AM
Why can't I export outlook contacts to Excel/Access, etc? Pat Outlook - Using Contacts 2 January 16th 07 11:04 PM
Figure out a way to synchronize Outlook folders on a home network susjs Outlook - Installation 3 August 23rd 06 04:57 PM
Export DL members to Excel CSV with Outlook VBA [email protected] Outlook and VBA 0 March 17th 06 08:04 PM
Export Excel to Outlook Contacts Kerri Outlook - Using Contacts 1 March 8th 06 08:43 PM


All times are GMT +1. The time now is 10:36 AM.


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.