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

open attachments



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old May 15th 06, 02:27 PM posted to microsoft.public.outlook.program_vba
Karsten Jung
external usenet poster
 
Posts: 2
Default open attachments

Hello together!

Perhaps you can help me.

var oAttachs = objMessage.Attachments;
var oAttach = oAttachs.Item(iAttach);

oAttach is the attachment I want to open.

Can I open it directly or do I have to save the attachment to the
FileSystem?

When the attachment must be saved to fileSystem, how can I remove the
file after e.g. word was closed?

I should not fill the disc ;-)

thanks, Karsten

Ads
  #2  
Old May 15th 06, 02:32 PM posted to microsoft.public.outlook.program_vba
Sue Mosher [MVP-Outlook]
external usenet poster
 
Posts: 11,651
Default open attachments

You must save the attachment to the file system. You can use FileSystemObject methods to delete the file. See http://www.outlookcode.com/d/code/copyatts.htm for sample code.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"Karsten Jung" wrote in message oups.com...
Hello together!

Perhaps you can help me.

var oAttachs = objMessage.Attachments;
var oAttach = oAttachs.Item(iAttach);

oAttach is the attachment I want to open.

Can I open it directly or do I have to save the attachment to the
FileSystem?

When the attachment must be saved to fileSystem, how can I remove the
file after e.g. word was closed?

I should not fill the disc ;-)

thanks, Karsten

  #3  
Old May 15th 06, 03:03 PM posted to microsoft.public.outlook.program_vba
Karsten Jung
external usenet poster
 
Posts: 2
Default open attachments


Sue Mosher [MVP-Outlook] schrieb:

You must save the attachment to the file system. You can use FileSystemObject methods to delete the file. See http://www.outlookcode.com/d/code/copyatts.htm for sample code.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx


Thank you, but I have to wait until word is closed, how to realize
this part? I cannot simply call FileSystemObject.Delete

Karsten

  #4  
Old May 15th 06, 03:18 PM posted to microsoft.public.outlook.program_vba
Sue Mosher [MVP-Outlook]
external usenet poster
 
Posts: 11,651
Default open attachments

Maybe your application could periodically look to see if there is a Word temporary file (beginning with ~) to match the file you saved. You might get other ideas in a Word forum.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"Karsten Jung" wrote in message ups.com...

Sue Mosher [MVP-Outlook] schrieb:

You must save the attachment to the file system. You can use FileSystemObject methods to delete the file. See http://www.outlookcode.com/d/code/copyatts.htm for sample code.


Thank you, but I have to wait until word is closed, how to realize
this part? I cannot simply call FileSystemObject.Delete


"Sue Mosher [MVP-Outlook]" wrote in message ...
You must save the attachment to the file system. You can use FileSystemObject methods to delete the file. See http://www.outlookcode.com/d/code/copyatts.htm for sample code.


"Karsten Jung" wrote in message oups.com...
Hello together!

Perhaps you can help me.

var oAttachs = objMessage.Attachments;
var oAttach = oAttachs.Item(iAttach);

oAttach is the attachment I want to open.

Can I open it directly or do I have to save the attachment to the
FileSystem?

When the attachment must be saved to fileSystem, how can I remove the
file after e.g. word was closed?

I should not fill the disc ;-)

thanks, Karsten

 




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
Can't open PPS attachments Ancient 1 Outlook Express 2 April 6th 06 09:16 PM
Can't open attachments Blair Outlook Express 3 March 22nd 06 09:00 PM
Cannot open picture attachments in OE skip42ms Outlook Express 4 February 12th 06 10:50 PM
Cannot open attachments on any emails jebrd601 Outlook Express 1 February 6th 06 09:03 PM
Can not open e-mail attachments LAURIE DAVIS Outlook Express 5 January 30th 06 04:38 AM


All times are GMT +1. The time now is 09:14 PM.


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.