Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

sending email notifications with file attachments in IBM CLM

 Dear All,

I'm using CLM 5.0.2 and i want to generate email notifications along with file attachments e.g. email notification for "Person A" with the attachment of daily report file.

I hope there must be a solution for this issue.

Waiting for the solution.

Regards,
Sajjad.

1 vote



3 answers

Permanent link
I doubt this is possible.  There are Email templates, but they do not allow attachments.  RRDI (If available) can be used to run reports on a schedule and can send them out via e-mail.

1 vote

Comments

 Thanks for replying me.


I think there must be some any technique through which i can attach file or the link of file or work item while sending email notification.
Please help me as i really need to either attach a file or attach the link of file when i send an email from the comments e.g. @UserID link of file/report/workitem which second user can view.

  Kevin Ramer


Thanks for replying me.

I think there must be some any technique through which i can attach file or the link of file or work item while sending email notification.
Please help me as i really need to either attach a file or attach the link of file when i send an email from the comments e.g. @UserID link of file/report/workitem which second user can view.

This is my opinion   RTC is not a notification/email system, so it should not be expected to behave like one.


Permanent link
In your question, it sounds like you want to automatically generate an email notification to a specific person, when you attach a file to a work item, and you want that email to contain that file attachment.  Is that correct?  In your comment above, you indicate that a link to that file would be sufficient (i.e. that it is OK for the email to contain a URL link to the attached file, rather than actually contain the file).   Is that correct?
If so:
- Add that specific person as a subscriber to the work item
- Have that person indicate in their RTC profile that they want to receive email notifications
- Every time you add an attachment to that work item, also add a comment containing the URL of the new attachment.
- That person will automatically get email with a link to the attachment.

1 vote


Permanent link
RTC provides below API in IMailerService to send mulitpart email messages -
public void sendMultipartMail(MailSender sender, String toAddress, String subject, Multipart msg, String cc) throws MessagingException;
I have used the same API to attach a file into email. Below is the sample code for same -

            // Create a multipart message
            Multipart multipart = new MimeMultipart();

            // Part1 is plain text. Create the plain text message and add into multipart
            BodyPart messageBodyPart = new MimeBodyPart();
            messageBodyPart.setText("Mail text Content");
            multipart.addBodyPart(messageBodyPart);

            // Part two is attachment, add that too into multipart
            messageBodyPart = new MimeBodyPart();
            DataSource source = new FileDataSource("/tmp/my_attachment");
            messageBodyPart.setDataHandler(new DataHandler(source));
            messageBodyPart.setFileName("AttachmentName");
            multipart.addBodyPart(messageBodyPart);

            mailerService.sendMultipartMail(mailerService.getDefaultSender(), "test@gmail.com",
                    "subject", multipart, null);

I suppose this would serve the purpose.

0 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 12,019
× 7,495
× 1,700

Question asked: Jul 09 '15, 8:56 a.m.

Question was seen: 7,117 times

Last updated: Feb 20 '16, 3:05 p.m.

Confirmation Cancel Confirm