Solved

How to detach attachments in notes?

Posted on 2000-05-11
4
429 Views
Last Modified: 2013-12-18
Hi

How do i detach attachments to a specified directory in notes by selecting the document and clicking a button. And also it should launch the application after detaching???
0
Comment
Question by:fenil
  • 2
4 Comments
 
LVL 5

Expert Comment

by:snocross
ID: 2800819
Are you saying you want to detach it programatically instead of manually specifying the location?  And are you also saying you want to automatically launch the attachment afterwards without having to manually double-click the attachment?
0
 
LVL 5

Accepted Solution

by:
snocross earned 200 total points
ID: 2800848
This script detaches and removes all the file attachments in a document's Body item that are larger than 100,000 bytes. (This size can be adjusted) The first file attachment that's found gets detached to c:\reports\newfile1, the second attachment that's found gets detached to c:\reports\newfile2, and so on.
Dim doc As NotesDocument
Dim rtitem As Variant
Dim fileCount As Integer
Const MAX = 100000
fileCount = 0
'...set value of doc...
Set rtitem = doc.GetFirstItem( "Body" )
If ( rtitem.Type = RICHTEXT ) Then
Forall o In rtitem.EmbeddedObjects
If ( o.Type = EMBED_ATTACHMENT ) _
And ( o.FileSize > MAX ) Then
fileCount = fileCount + 1
Call o.ExtractFile _
( "c:\reports\newfile" & Cstr(fileCount) )
Call o.Remove
Call doc.Save( True, True )
End If
End Forall
End If
0
 
LVL 9

Expert Comment

by:Arunkumar
ID: 2802682
Hi Fenil,

Did you say that you want to detach attachments from a mail or attachments from a "Body" field ?

Jus Curious...

Can you give a bit more explaination on the document that you want to process ?

-Arun


0
 

Author Comment

by:fenil
ID: 2803317
Yeah it worked when i added the handle to the document etc...

Thanks
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Lotus Notes 8.5 1 140
Domino Application - View Refresh on Subform 15 95
Lotus Notes default email application problem 6 115
See used databases in Domino 8 100
For users on the Lotus Notes 8 Standard client, this article provides information on checking the Java Heap size and adjusting it to half of your system RAM in attempt to get the Lotus Notes 8.x Standard client to run faster.  I've had to exercise t…
You’ve got a lotus Domino web server, and you have been told that “leverage browser caching” is a must do. This means that we have to tell the browser everywhere in the web to use cache. In other words, we set (and send) an expiration date in the HT…
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now