Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

How to detach attachments in notes?

Posted on 2000-05-11
4
433 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

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Why won't this building block macro run? 6 289
names.nsf ODS upgrade 4 454
Username format for Domino LDAP 3 102
Save conflict messages on existing documents 15 74
I thought it will be a good idea to make a post as it will help in case someone else faces these issues. I trust this gives an idea how each entry in Notes.ini can mean a lot for the Domino Server to be functioning properly. This article discusses t…
IBM Notes offer Encryption feature using which the user can secure its NSF emails or entire database easily. In this section we will discuss about the process to Encrypt Incoming and Outgoing Mails in depth.
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

840 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