Attachment Implementation

Hi,
I am doing an Attachment implementation in my UI. I gone throught the stpes given in this url http://docs.oracle.com/cd/E25178_01/fusionapps.1111/e15524/ui_attachments.htm
I created my business object VO and then added Applications Core (Attachments Model) to my Model project. After adding the library to your model, navigate to Application Navigator >Application Resources >Descriptors >META-INF and add the following xml snippet to your jazn-data.xml file, granted permission.
But after that I stuck at creating a view link. Followed steps in the section How to Create Attachment View Links and as given in the figure Figure 19-5 Create Attachment View Link Wizard — Name (Step 1), click on Next, got the error message saying "The Attachments View Object is not available in the current project. Please import it using the file - Import, Business Components command.
Please help.

Hi,
wrong forum. This is about Oracle JDeveloper and ADF and not Oracle Applications.
Frank

Similar Messages

  • BPM Attachment server URL is always 127.0.0.1

    Hi,
    my name is Dmitry and my issue is the foolowing: I have a huge BPM application (BPM Suite 11g, Weblogic 10.3.6) with customized ADF forms. Each form has attachments tab which has standard attachment implementation taken from auto-generated form. The problem is that attachments can be opened only from the machine with weblogic server where the applciation is deployed since the attachment URL always points to 127.0.0.1. The URL is completely correct and can be opened from other machines when 127.0.0.1 is manually changed in the address bar to the DNS name of the server. But from the very application it cannot be opened from other machines where there's no weblogic.
    Other URLs like tabs URLs on the form, application URLs - they all have a correct DNS name of the server and can be opened from anywhere.
    The attachment URL is always the following.
    http://127.0.0.1:7001/integration/services/ADFAttachmentHelper?bpmWorklistContext=db14d66c-7bc6-4054-8167-af89127112da%3B%3BJ9Y5pEfNJd5bAA8g8s%2Fyco%2BSfTTXR%2Bge9MbLO0ZZ39fxqZzNGk8001qXFBmCop2JQVvhD0yCSD68DLiLXotjOs0J6n8u%2FmpY1q98EsK076MrNdQCIZF767IKPuD3kRViY73%2FXXEbKU5YS13636eV6rNUapYFqUyrl4OWuKukinlrQ84fv6NfAPxADpnHD9CBanaoR2P9jDk826%2B%2BPixHI7fuIvtfTI5%2BS7dWdBpDvYKHROqjdgRrBJGIvJVwfsjn&bpmWorklistTaskId=b4e4a8f2-286e-42ca-b208-93e721a1a02a&QueryAttachment=QueryAttachment&WFTASK_ATTACHMENT_NAME=Writing.doc&bpmWorklistTaskVersion=1&cid=b4e4a8f2-286e-42ca-b208-93e721a1a02a
    And I need it to be
    http://my_server_name:7001/integration/services/ADFAttachmentHelper?bpmWorklistContext=db14d66c-7bc6-4054-8167-af89127112da%3B%3BJ9Y5pEfNJd5bAA8g8s%2Fyco%2BSfTTXR%2Bge9MbLO0ZZ39fxqZzNGk8001qXFBmCop2JQVvhD0yCSD68DLiLXotjOs0J6n8u%2FmpY1q98EsK076MrNdQCIZF767IKPuD3kRViY73%2FXXEbKU5YS13636eV6rNUapYFqUyrl4OWuKukinlrQ84fv6NfAPxADpnHD9CBanaoR2P9jDk826%2B%2BPixHI7fuIvtfTI5%2BS7dWdBpDvYKHROqjdgRrBJGIvJVwfsjn&bpmWorklistTaskId=b4e4a8f2-286e-42ca-b208-93e721a1a02a&QueryAttachment=QueryAttachment&WFTASK_ATTACHMENT_NAME=Writing.doc&bpmWorklistTaskVersion=1&cid=b4e4a8f2-286e-42ca-b208-93e721a1a02a
    I have even configure UCM integration but the attachment put into the UCM in the attachments table still have the 127.0.0.1 URL.
    I guess this is configuration issue. Does anyone have any idea how it can be fixed? It's critical.
    Thanks a lot,

    Hi Dmitry,
    Take a look at these two threads to see if they might help with your UCM issue:
    https://forums.oracle.com/message/10160948#10160948
    https://forums.oracle.com/thread/2296123

  • Using attachments with javamail

    Hi
    I wonder if anyone could help me. Is is possible to send an (oracle)blob as an attachment using javamail? How would I go about doing this? Thanks in advance

    You can attach arbitrary binary data to an email sent through javamail. How the recipient interprets that data depends on the mime type and on their email client. I think a mime type of application/octet-stream will result in a binary file for which the only option is saving to disk.
    Below are code snippets from part of a program in which I deal with attachments. They are far from complete, but show all the important method calls.
    import javax.mail.*;
    import javax.mail.internet.*;
    attachment = (NotifyInterface.Attachment)allData.getObject();
    headers = new InternetHeaders();
    headers.addHeader("Content-Type", attachment.getMimeType());
    encodedData = base64Encode(attachment.getData());
    mbpAttachment=new MimeBodyPart(headers, encodedData);
    mbpAttachment.setFileName(attachment.getFileName());
    mbpAttachment.setDisposition(MimeMessage.ATTACHMENT);
    mbpAttachment.setHeader("Content-Transfer-Encoding", "base64");
    byte[] base64Encode(byte[] rawData) throws MessagingException {
    ByteArrayOutputStream bout = new ByteArrayOutputStream();
    OutputStream out = MimeUtility.encode(bout, "base64");
    try {
    out.write(rawData);
    out.close();
    } catch(IOException e) {
    throw (MessagingException)new MessagingException("Error encoding attachment").initCause(e);
    return bout.toByteArray();
    public static class Attachment implements Serializable {
    String fileName;
    String mimeType;
    byte[] data;
    public Attachment(String fileName, byte[] data, String mimeType) {
    this.fileName = fileName;
    this.data = data;
    this.mimeType = mimeType;
    public String getFileName() {
    return fileName;
    public String getMimeType() {
    return mimeType;
    public byte[] getData() {
    return data;
    public String toString() {
    return "Attachment of type "+mimeType;

  • Using C+ Function "QSORT" in LV

    Hi all,
    I'm converting some C+ code to LabVIEW. 
    I want to use the C+ "QSORT" function as I cannot find an equivalent in LV.  Is there one?
    Can I use the Code Interface Node?  I don't have a C compiler.  I don't know how to write a C file.
    Here is a description of the QSORT function taken from the Using External Code in LV manual (p276):
    QSortvoid QSort(arrayp, n, elmtSize, compareProcP());PurposeSorts an array of an arbitrary data type using the QuickSort algorithm. In addition to passing
    the array you want to sort to this routine, you also pass a comparison procedure that this sort
    routine then uses to compare elements in the array.The comparison routine should return a number less than zero if a is less than b, zero if a is equal to b, and a number greater than zero if a is greater than b.
    You should declare the comparison routine to have the following parameters and return type.
    int32 compareProcP(UPtr a, UPtr b);ParametersName Type Description
    arrayp Uptr Pointer to an array of data.n int32 Number of elements in the array you want to sort.elmtSize int32 Size in bytes of an array element.compareProcP CompareProcPtr Comparison routine you want QSort to useto compare array elements. QSort passes this routine the addresses of two elements
    that it needs to compare.

    I found a couple of QUICK SORT LV implementations.
    They appear to work for simple numeric arrays but I cannot get them to work for my application.  I'm trying to implement the Graham's (Hull) Algorithm (see here).
    Attached are a couple of the implementations.  I got them from here and another place.
    I'm trying to sort cluster array.  My Compare function compares 3 (not 2) array elements.  It appears to sort some of my array correctly but may be terminating early.  The attached implementations call only 2 instances of QSORT recursively.. do I need more?..
    Message Edited by battler. on 05-22-2010 09:24 PM
    Attachments:
    Recursion-in-LabVIEW-Examples.zip ‏134 KB
    lvqsort-0.1.zip ‏37 KB

  • DataGrid or AdvancedDataGrid to implement this ?? Image Attached

    Hi ,
    Please see the Image attached with this Thread .
    I need to implement this kind of Feature in my Application .
    I need to show Employee Image , Emp Name , Email Address and Linked link if avialable .
    I would be getting all this data in XML Format with the help of HttpService from a Servlet .
    Please suggest whether i should use DataGrid or AdvancedDataGrid to implement this Feature ??
    I am using FLEX 3 for my development .

    Thanks for the reply .
    Currently we are using DataGrid to just show the Name on to DataGrid Column .
    Now we want to extend this fuctionality to show all these above  features on to the DataGrid Column , so please guide .
    Thanks .

  • How to implement attachment table in create page

    Hi
    I tried to add an attachment table in create page,but the table is not appearing.
    Is it because that the primary key attribute mapped to attachment table is committed only after clicking submit button in create page?.
    I am using a sequence for primary key.
    Thanks,
    Sridharan

    Hi ,
    Please see following post in forum
    Attachment table is not appearing in the page.
    Thanks ,
    Ashish

  • Implementation of DataHandler and SOAP with attachment

    HI, i have found an example that illustrates the reception and return of SOAP attachments
    in web service method. However, the weblogic workshop I am using does not recognise
    'DataHandler'. I typed 'public String echoAttachment(DataHandler dh) and it said
    'web service does not support such data type'. Is there any resolution to it?
    And if convenient, can i have the source code of attaching images to SOAP?
    Thanks alot.
    Good Day!
    grazieee
    P/S: I'm using weblogic version 8.1

    http://newsgroups.bea.com/cgi-bin/dnewsweb?cmd=article&group=weblogic.developer.interest.webservices&item=4967
    grazieee wrote:
    >
    HI, i have found an example that illustrates the reception and return of SOAP attachments
    in web service method. However, the weblogic workshop I am using does not recognise
    'DataHandler'. I typed 'public String echoAttachment(DataHandler dh) and it said
    'web service does not support such data type'. Is there any resolution to it?
    And if convenient, can i have the source code of attaching images to SOAP?
    Thanks alot.
    Good Day!
    grazieee
    P/S: I'm using weblogic version 8.1

  • Error while attaching document to report on Portal - Invalid selection valu

    Hello All,
    We are running our reports on Portal and as per the business requirement the users have to create comments or attach documents to certain amounts in certain columns and once they create the comment a document icon shows up near that amount (for example there are 3 columns Budget, actual, balance then the user have to create comment for some amounts which needs explanation) they do that from context menu  Documents -> Create new Comment.
    Now we want those documents to be saved on Infoprovider level and not on master data for any particular object. We have activated the flag "Characteristic is document property" on related infoobjects. We have the flag to display document icon on Infoprovider active in the web template. Now when I run the report I am able to create new comments on first two columns and when the report refreshes it shows me icon near that amount but it gives me errors on third column after the report refreshes itself. Now when I go in portal KM repository where documents are stored I do see the document that I created for the third column as well so looks like the document is getting created and being stored but the issue is when it tries to display the icon on that third column.
    The error I get is this:
    The initial exception that caused the request to fail was:
    Invalid selection value:  AttributeMember
    com.sap.ip.bi.bics.dataaccess.resource.impl.bi.exceptions.BicsResourceBwRuntimeException: Invalid selection value:  AttributeMember
    at com.sap.ip.bi.bics.dataaccess.resource.impl.bi.selector.selection.ProviderRange.setLowForced(ProviderRange.java:297)
    at com.sap.ip.bi.bics.dataaccess.resource.impl.bi.selector.selection.ProviderRange.setLow(ProviderRange.java:291)
    at com.sap.ip.bi.bics.dataaccess.resource.impl.bi.selector.selection.ProviderRange.set(ProviderRange.java:469)
    at com.sap.ip.bi.bics.dataaccess.consumer.impl.selector.selection.SingleMember.set(SingleMember.java:125)
    at com.sap.ip.bi.km.common.assignment.AssignmentMember.isContained(AssignmentMember.java:192)
    Please give some inputs if anyone is facing same problem or is anyone has worked previously with this kinda of stuff.
    Thanks in advance.
    Kiran

    Hi!
    Have you solved this problem? I have the same problem after a SPS implementation (SPS 17). The message appears when we select a single value in a DP (hierarchical filter item) that filters another one, but when I select a node it doesn't.
    Before the patch implementation the apliccation worked ok.
    Any idea?
    Thanks in advance.
    Jose

  • HOW TO SEND A HEBREW EMAIL WITH ATTACHMENT USING DEMO_MAIL

    Hello All,
    This is Not a question , just attaching something I've implemented and might be interesting for few of us,
    This package I'm attaching allows to send Hebrew Language email + attaching files to it.
    This package is based on demo_mail package (combined here but you can search at google for more example information if needed).
    My Package is supplied as is , for any specific information regarding it , please contact me directly at : [email protected] or POST here.
    * Please also note , that this package allow file to be attach via URL (meaning you will have to define a link to this file, if you would like to implement a link to a local file , e.g : c:\temp\myfile , you will have to customize the package your self with database directories option etc ...)
    First I will attach an example of how to use it :
    ==================================
    begin
    demo_mail_heb.send_html_mail_attach(p_sender => '[email protected]',
    p_recipients => '[email protected]',
    p_subject => 'שלום וברכה עולם',
    p_data => '<hr><b>בוקר טוב</b><hr>',
    p_file_name => 'but_choose_file.gif',
    p_file_mime_type => 'application/pdf',
    p_file_URL => 'http://10.172.246.160:7777/i/but_choose_file.gif');
    end;
    Second Here is the Package (please note you will have to modify few settings in order to enable it , such as mail server address ..etc)
    ======================================================================================
    CREATE OR REPLACE PACKAGE demo_mail_heb IS
    ----------------------- Customizable Section -----------------------
    -- Customize the SMTP host, port and your domain name below.
    smtp_host VARCHAR2(256) := 'mail.oracle.com';
    smtp_port PLS_INTEGER := 25;
    smtp_domain VARCHAR2(256) := 'oracle.com';
    -- Customize the signature that will appear in the email's MIME header.
    -- Useful for versioning.
    MAILER_ID CONSTANT VARCHAR2(256) := 'Mailer by Oracle UTL_SMTP';
    --------------------- End Customizable Section ---------------------
    -- A unique string that demarcates boundaries of parts in a multi-part email
    -- The string should not appear inside the body of any part of the email.
    -- Customize this if needed or generate this randomly dynamically.
    BOUNDARY CONSTANT VARCHAR2(256) := '-----7D81B75CCC90D2974F7A1CBD';
    FIRST_BOUNDARY CONSTANT VARCHAR2(256) := '--' || BOUNDARY || utl_tcp.CRLF;
    LAST_BOUNDARY CONSTANT VARCHAR2(256) := '--' || BOUNDARY || '--' ||
    utl_tcp.CRLF;
    -- A MIME type that denotes multi-part email (MIME) messages.
    MULTIPART_MIME_TYPE CONSTANT VARCHAR2(256) := 'multipart/mixed; boundary="'||
    BOUNDARY || '"';
    MAX_BASE64_LINE_WIDTH CONSTANT PLS_INTEGER := 76 / 4 * 3;
    -- Sent clear Html Email
    procedure send_html_mail (p_sender in varchar2 default null,
    p_recipients in varchar2 default null,
    p_subject in varchar2 default null,
    p_data in varchar2 default null,
    p_mime_type in varchar2 default 'text/html; charset=windows-1255');
    -- Sent Html Email with Attachment
    procedure send_html_mail_attach (p_sender in varchar2 default null,
    p_recipients in varchar2 default null,
    p_subject in varchar2 default null,
    p_data in varchar2 default '<b>áå÷ø èåá òåìí - áãé÷ä</b',
    p_mime_type in varchar2 default demo_mail_heb.MULTIPART_MIME_TYPE,
    p_file_name in varchar2 default 'but_choose_file.gif',
    p_file_mime_type in varchar2 default 'application/pdf',
    p_file_URL in varchar2 default 'http://10.172.246.160:7777/i/but_choose_file.gif');
    -- A simple email API for sending email in plain text in a single call.
    -- The format of an email address is one of these:
    -- someone@some-domain
    -- "Someone at some domain" <someone@some-domain>
    -- Someone at some domain <someone@some-domain>
    -- The recipients is a list of email addresses separated by
    -- either a "," or a ";"
    PROCEDURE mail(sender IN VARCHAR2,
              recipients IN VARCHAR2,
              subject IN VARCHAR2,
              message IN VARCHAR2);
    -- Extended email API to send email in HTML or plain text with no size limit.
    -- First, begin the email by begin_mail(). Then, call write_text() repeatedly
    -- to send email in ASCII piece-by-piece. Or, call write_mb_text() to send
    -- email in non-ASCII or multi-byte character set. End the email with
    -- end_mail().
    FUNCTION begin_mail(sender IN VARCHAR2,
              recipients IN VARCHAR2,
              subject IN VARCHAR2,
              mime_type IN VARCHAR2 DEFAULT 'text/plain',
              priority IN PLS_INTEGER DEFAULT NULL)
              RETURN utl_smtp.connection;
    -- Write email body in ASCII
    PROCEDURE write_text(conn IN OUT NOCOPY utl_smtp.connection,
              message IN VARCHAR2);
    -- Write email body in non-ASCII (including multi-byte). The email body
    -- will be sent in the database character set.
    PROCEDURE write_mb_text(conn IN OUT NOCOPY utl_smtp.connection,
                   message IN VARCHAR2);
    -- Write email body in binary
    PROCEDURE write_raw(conn IN OUT NOCOPY utl_smtp.connection,
              message IN RAW);
    -- APIs to send email with attachments. Attachments are sent by sending
    -- emails in "multipart/mixed" MIME format. Specify that MIME format when
    -- beginning an email with begin_mail().
    -- Send a single text attachment.
    PROCEDURE attach_text(conn IN OUT NOCOPY utl_smtp.connection,
                   data IN VARCHAR2,
                   mime_type IN VARCHAR2 DEFAULT 'text/plain',
                   inline IN BOOLEAN DEFAULT TRUE,
                   filename IN VARCHAR2 DEFAULT NULL,
              last IN BOOLEAN DEFAULT FALSE);
    -- Send a binary attachment. The attachment will be encoded in Base-64
    -- encoding format.
    PROCEDURE attach_base64(conn IN OUT NOCOPY utl_smtp.connection,
                   data IN RAW,
                   mime_type IN VARCHAR2 DEFAULT 'application/octet',
                   inline IN BOOLEAN DEFAULT TRUE,
                   filename IN VARCHAR2 DEFAULT NULL,
                   last IN BOOLEAN DEFAULT FALSE);
    -- Send an attachment with no size limit. First, begin the attachment
    -- with begin_attachment(). Then, call write_text repeatedly to send
    -- the attachment piece-by-piece. If the attachment is text-based but
    -- in non-ASCII or multi-byte character set, use write_mb_text() instead.
    -- To send binary attachment, the binary content should first be
    -- encoded in Base-64 encoding format using the demo package for 8i,
    -- or the native one in 9i. End the attachment with end_attachment.
    PROCEDURE begin_attachment(conn IN OUT NOCOPY utl_smtp.connection,
                   mime_type IN VARCHAR2 DEFAULT 'text/plain',
                   inline IN BOOLEAN DEFAULT TRUE,
                   filename IN VARCHAR2 DEFAULT NULL,
                   transfer_enc IN VARCHAR2 DEFAULT NULL);
    -- End the attachment.
    PROCEDURE end_attachment(conn IN OUT NOCOPY utl_smtp.connection,
                   last IN BOOLEAN DEFAULT FALSE);
    -- End the email.
    PROCEDURE end_mail(conn IN OUT NOCOPY utl_smtp.connection);
    -- Extended email API to send multiple emails in a session for better
    -- performance. First, begin an email session with begin_session.
    -- Then, begin each email with a session by calling begin_mail_in_session
    -- instead of begin_mail. End the email with end_mail_in_session instead
    -- of end_mail. End the email session by end_session.
    FUNCTION begin_session RETURN utl_smtp.connection;
    -- Begin an email in a session.
    PROCEDURE begin_mail_in_session(conn IN OUT NOCOPY utl_smtp.connection,
                        sender IN VARCHAR2,
                        recipients IN VARCHAR2,
                        subject IN VARCHAR2,
    --                     mime_type IN VARCHAR2 DEFAULT 'text/plain; charset=windows-1255',
              mime_type IN VARCHAR2 DEFAULT 'text/plain',
                        priority IN PLS_INTEGER DEFAULT NULL);
    -- End an email in a session.
    PROCEDURE end_mail_in_session(conn IN OUT NOCOPY utl_smtp.connection);
    -- End an email session.
    PROCEDURE end_session(conn IN OUT NOCOPY utl_smtp.connection);
    END;
    CREATE OR REPLACE PACKAGE BODY demo_mail_heb IS
    -- Sent clear Html Email
    procedure send_html_mail (p_sender in varchar2 default null,
    p_recipients in varchar2 default null,
    p_subject in varchar2 default null,
    p_data in varchar2 default null,
    p_mime_type in varchar2 default 'text/html; charset=windows-1255')
    Is
    conn utl_smtp.connection;
    BEGIN
    conn := demo_mail_heb.begin_mail(
    sender => p_sender,
    recipients => p_recipients,
    subject => p_subject,
    mime_type => p_mime_type);
    demo_mail_heb.write_text(
    conn => conn,
    message => p_data);
    demo_mail_heb.end_mail( conn => conn );
    END;
    -- Sent Html Email with Attachment
    procedure send_html_mail_attach (p_sender in varchar2 default null,
    p_recipients in varchar2 default null,
    p_subject in varchar2 default null,
    p_data in varchar2 default '<b>áå÷ø èåá òåìí - áãé÷ä</b',
    p_mime_type in varchar2 default demo_mail_heb.MULTIPART_MIME_TYPE,
    p_file_name in varchar2 default 'but_choose_file.gif',
    p_file_mime_type in varchar2 default 'application/pdf',
    p_file_URL in varchar2 default 'http://10.172.246.160:7777/i/but_choose_file.gif')
    is
    conn utl_smtp.connection;
    req utl_http.req;
    resp utl_http.resp;
    data RAW(200);
    begin
    conn := demo_mail_heb.begin_mail(
    sender => p_sender,
    recipients => p_recipients,
    subject => p_subject,
    mime_type => p_mime_type);
    demo_mail_heb.attach_text(
    conn => conn,
    data => p_data,
    mime_type => 'text/html');
    demo_mail_heb.begin_attachment(
    conn => conn,
    mime_type => p_file_mime_type,
    inline => TRUE,
    filename => p_file_name,
    transfer_enc => 'base64');
    -- In writing Base-64 encoded text following the MIME format below,
    -- the MIME format requires that a long piece of data must be splitted
    -- into multiple lines and each line of encoded data cannot exceed
    -- 80 characters, including the new-line characters. Also, when
    -- splitting the original data into pieces, the length of each chunk
    -- of data before encoding must be a multiple of 3, except for the
    -- last chunk. The constant demo_mail_heb.MAX_BASE64_LINE_WIDTH
    -- (76 / 4 * 3 = 57) is the maximum length (in bytes) of each chunk
    -- of data before encoding.
    Utl_Http.set_proxy('www-proxy.us.oracle.com', 'oracle.com');
    req := utl_http.begin_request(p_file_URL);
    resp := utl_http.get_response(req);
    BEGIN
    LOOP
    utl_http.read_raw(resp, data, demo_mail_heb.MAX_BASE64_LINE_WIDTH);
    demo_mail_heb.write_raw(
    conn => conn,
    message => utl_encode.base64_encode(data));
    END LOOP;
    EXCEPTION
    WHEN utl_http.end_of_body THEN
    utl_http.end_response(resp);
    END;
    demo_mail_heb.end_attachment( conn => conn );
    demo_mail_heb.end_mail( conn => conn );
    end;
    -- Return the next email address in the list of email addresses, separated
    -- by either a "," or a ";". The format of mailbox may be in one of these:
    -- someone@some-domain
    -- "Someone at some domain" <someone@some-domain>
    -- Someone at some domain <someone@some-domain>
    FUNCTION get_address(addr_list IN OUT VARCHAR2) RETURN VARCHAR2 IS
    addr VARCHAR2(256);
    i pls_integer;
    FUNCTION lookup_unquoted_char(str IN VARCHAR2,
                        chrs IN VARCHAR2) RETURN pls_integer AS
    c VARCHAR2(5);
    i pls_integer;
    len pls_integer;
    inside_quote BOOLEAN;
    BEGIN
    inside_quote := false;
    i := 1;
    len := length(str);
    WHILE (i <= len) LOOP
         c := substr(str, i, 1);
         IF (inside_quote) THEN
         IF (c = '"') THEN
         inside_quote := false;
         ELSIF (c = '\') THEN
         i := i + 1; -- Skip the quote character
         END IF;
         GOTO next_char;
         END IF;
         IF (c = '"') THEN
         inside_quote := true;
         GOTO next_char;
         END IF;
         IF (instr(chrs, c) >= 1) THEN
         RETURN i;
         END IF;
         <<next_char>>
         i := i + 1;
    END LOOP;
    RETURN 0;
    END;
    BEGIN
    addr_list := ltrim(addr_list);
    i := lookup_unquoted_char(addr_list, ',;');
    IF (i >= 1) THEN
    addr := substr(addr_list, 1, i - 1);
    addr_list := substr(addr_list, i + 1);
    ELSE
    addr := addr_list;
    addr_list := '';
    END IF;
    i := lookup_unquoted_char(addr, '<');
    IF (i >= 1) THEN
    addr := substr(addr, i + 1);
    i := instr(addr, '>');
    IF (i >= 1) THEN
         addr := substr(addr, 1, i - 1);
    END IF;
    END IF;
    RETURN addr;
    END;
    -- Write a MIME header
    PROCEDURE write_mime_header(conn IN OUT NOCOPY utl_smtp.connection,
                   name IN VARCHAR2,
                   value IN VARCHAR2) IS
    BEGIN
    -- utl_smtp.write_data(conn, name || ': ' || value || utl_tcp.CRLF);
    utl_smtp.write_raw_data(conn, UTL_RAW.CAST_TO_RAW(name || ': ' ||value || utl_tcp.CRLF));
    END;
    -- Mark a message-part boundary. Set <last> to TRUE for the last boundary.
    PROCEDURE write_boundary(conn IN OUT NOCOPY utl_smtp.connection,
                   last IN BOOLEAN DEFAULT FALSE) AS
    BEGIN
    IF (last) THEN
    utl_smtp.write_data(conn, LAST_BOUNDARY);
    ELSE
    utl_smtp.write_data(conn, FIRST_BOUNDARY);
    END IF;
    END;
    PROCEDURE mail(sender IN VARCHAR2,
              recipients IN VARCHAR2,
              subject IN VARCHAR2,
              message IN VARCHAR2) IS
    conn utl_smtp.connection;
    BEGIN
    conn := begin_mail(sender, recipients, subject);
    write_text(conn, message);
    end_mail(conn);
    END;
    FUNCTION begin_mail(sender IN VARCHAR2,
              recipients IN VARCHAR2,
              subject IN VARCHAR2,
              mime_type IN VARCHAR2 DEFAULT 'text/plain',
              priority IN PLS_INTEGER DEFAULT NULL)
              RETURN utl_smtp.connection IS
    conn utl_smtp.connection;
    BEGIN
    conn := begin_session;
    begin_mail_in_session(conn, sender, recipients, subject, mime_type,
    priority);
    RETURN conn;
    END;
    PROCEDURE write_text(conn IN OUT NOCOPY utl_smtp.connection,
              message IN VARCHAR2) IS
    BEGIN
    utl_smtp.write_raw_data(conn, utl_raw.cast_to_raw(CONVERT(message,'IW8ISO8859P8')));
    END;
    PROCEDURE write_mb_text(conn IN OUT NOCOPY utl_smtp.connection,
                   message IN VARCHAR2) IS
    BEGIN
    utl_smtp.write_raw_data(conn, utl_raw.cast_to_raw(message));
    END;
    PROCEDURE write_raw(conn IN OUT NOCOPY utl_smtp.connection,
              message IN RAW) IS
    BEGIN
    utl_smtp.write_raw_data(conn, message);
    END;
    PROCEDURE attach_text(conn IN OUT NOCOPY utl_smtp.connection,
                   data IN VARCHAR2,
                   mime_type IN VARCHAR2 DEFAULT 'text/plain',
                   inline IN BOOLEAN DEFAULT TRUE,
                   filename IN VARCHAR2 DEFAULT NULL,
              last IN BOOLEAN DEFAULT FALSE) IS
    BEGIN
    begin_attachment(conn, mime_type, inline, filename);
    write_text(conn, data);
    end_attachment(conn, last);
    END;
    PROCEDURE attach_base64(conn IN OUT NOCOPY utl_smtp.connection,
                   data IN RAW,
                   mime_type IN VARCHAR2 DEFAULT 'application/octet',
                   inline IN BOOLEAN DEFAULT TRUE,
                   filename IN VARCHAR2 DEFAULT NULL,
                   last IN BOOLEAN DEFAULT FALSE) IS
    i PLS_INTEGER;
    len PLS_INTEGER;
    BEGIN
    begin_attachment(conn, mime_type, inline, filename, 'base64');
    -- Split the Base64-encoded attachment into multiple lines
    i := 1;
    len := utl_raw.length(data);
    WHILE (i < len) LOOP
    IF (i + MAX_BASE64_LINE_WIDTH < len) THEN
         utl_smtp.write_raw_data(conn,
         utl_encode.base64_encode(utl_raw.substr(data, i,
         MAX_BASE64_LINE_WIDTH)));
    ELSE
         utl_smtp.write_raw_data(conn,
         utl_encode.base64_encode(utl_raw.substr(data, i)));
    END IF;
    utl_smtp.write_data(conn, utl_tcp.CRLF);
    i := i + MAX_BASE64_LINE_WIDTH;
    END LOOP;
    end_attachment(conn, last);
    END;
    PROCEDURE begin_attachment(conn IN OUT NOCOPY utl_smtp.connection,
                   mime_type IN VARCHAR2 DEFAULT 'text/plain',
                   inline IN BOOLEAN DEFAULT TRUE,
                   filename IN VARCHAR2 DEFAULT NULL,
                   transfer_enc IN VARCHAR2 DEFAULT NULL) IS
    BEGIN
    write_boundary(conn);
    write_mime_header(conn, 'Content-Type', mime_type);
    IF (filename IS NOT NULL) THEN
    IF (inline) THEN
         write_mime_header(conn, 'Content-Disposition',
         'inline; filename="'||filename||'"');
    ELSE
         write_mime_header(conn, 'Content-Disposition',
         'attachment; filename="'||filename||'"');
    END IF;
    END IF;
    IF (transfer_enc IS NOT NULL) THEN
    write_mime_header(conn, 'Content-Transfer-Encoding', transfer_enc);
    END IF;
    utl_smtp.write_data(conn, utl_tcp.CRLF);
    END;
    PROCEDURE end_attachment(conn IN OUT NOCOPY utl_smtp.connection,
                   last IN BOOLEAN DEFAULT FALSE) IS
    BEGIN
    utl_smtp.write_data(conn, utl_tcp.CRLF);
    IF (last) THEN
    write_boundary(conn, last);
    END IF;
    END;
    PROCEDURE end_mail(conn IN OUT NOCOPY utl_smtp.connection) IS
    BEGIN
    end_mail_in_session(conn);
    end_session(conn);
    END;
    FUNCTION begin_session RETURN utl_smtp.connection IS
    conn utl_smtp.connection;
    BEGIN
    -- open SMTP connection
    conn := utl_smtp.open_connection(smtp_host, smtp_port);
    utl_smtp.helo(conn, smtp_domain);
    RETURN conn;
    END;
    PROCEDURE begin_mail_in_session(conn IN OUT NOCOPY utl_smtp.connection,
                        sender IN VARCHAR2,
                        recipients IN VARCHAR2,
                        subject IN VARCHAR2,
                        mime_type IN VARCHAR2 DEFAULT 'text/plain',
                   --     mime_type IN VARCHAR2 DEFAULT 'text/plain; charset=windows-1255',
                        priority IN PLS_INTEGER DEFAULT NULL) IS
    my_recipients VARCHAR2(32767) := recipients;
    my_sender VARCHAR2(32767) := sender;
    BEGIN
    -- Specify sender's address (our server allows bogus address
    -- as long as it is a full email address ([email protected]).
    utl_smtp.mail(conn, get_address(my_sender));
    -- Specify recipient(s) of the email.
    WHILE (my_recipients IS NOT NULL) LOOP
    utl_smtp.rcpt(conn, get_address(my_recipients));
    END LOOP;
    -- Start body of email
    utl_smtp.open_data(conn);
    -- Set "From" MIME header
    write_mime_header(conn, 'From', sender);
    -- Set "To" MIME header
    write_mime_header(conn, 'To', recipients);
    -- Set "Subject" MIME header
    write_mime_header(conn, 'Subject', subject);
    -- Set "Content-Type" MIME header
    write_mime_header(conn, 'Content-Type', mime_type);
    -- Set "X-Mailer" MIME header
    write_mime_header(conn, 'X-Mailer', MAILER_ID);
    -- Set priority:
    -- High Normal Low
    -- 1 2 3 4 5
    IF (priority IS NOT NULL) THEN
    write_mime_header(conn, 'X-Priority', priority);
    END IF;
    -- Send an empty line to denotes end of MIME headers and
    -- beginning of message body.
    utl_smtp.write_data(conn, utl_tcp.CRLF);
    IF (mime_type LIKE 'multipart/mixed%') THEN
    write_text(conn, 'This is a multi-part message in MIME format.' ||
         utl_tcp.crlf);
    END IF;
    END;
    PROCEDURE end_mail_in_session(conn IN OUT NOCOPY utl_smtp.connection) IS
    BEGIN
    utl_smtp.close_data(conn);
    END;
    PROCEDURE end_session(conn IN OUT NOCOPY utl_smtp.connection) IS
    BEGIN
    utl_smtp.quit(conn);
    END;
    END;

    Hello All,
    Small modification - use this package and not the above
    HERE IS A WORKING CODE FOR SENDING HEBREW MESSAGES (INCLUDING SUBJECT IN UTF-8 APPEAR IN ALL EMAIL CLIENTS I HAVE CHECKED) + ATTACHMENTS
    Code attached below is supplied as is with no support. anyhow if help is needed , please contact me via [email protected]
    ============================================================================
    CREATE OR REPLACE PACKAGE demo_mail_heb IS
    ----------------------- Customizable Section -----------------------
    -- Customize the SMTP host, port and your domain name below.
    smtp_host VARCHAR2(256) := pst_ajax.getParameter('EMAIL_SMTP_HOST');
    smtp_port PLS_INTEGER := pst_ajax.getParameter('EMAIL_SMTP_PORT');
    smtp_domain VARCHAR2(256) := pst_ajax.getParameter('EMAIL_SMTP_DOMAIN');
    -- Customize the signature that will appear in the email's MIME header.
    -- Useful for versioning.
    MAILER_ID CONSTANT VARCHAR2(256) := 'Mailer by Oracle UTL_SMTP';
    --------------------- End Customizable Section ---------------------
    -- A unique string that demarcates boundaries of parts in a multi-part email
    -- The string should not appear inside the body of any part of the email.
    -- Customize this if needed or generate this randomly dynamically.
    BOUNDARY CONSTANT VARCHAR2(256) := '-----7D81B75CCC90D2974F7A1CBD';
    FIRST_BOUNDARY CONSTANT VARCHAR2(256) := '--' || BOUNDARY || utl_tcp.CRLF;
    LAST_BOUNDARY CONSTANT VARCHAR2(256) := '--' || BOUNDARY || '--' ||
    utl_tcp.CRLF;
    -- A MIME type that denotes multi-part email (MIME) messages.
    MULTIPART_MIME_TYPE CONSTANT VARCHAR2(256) := 'multipart/mixed; boundary="'||
    BOUNDARY || '"';
    MAX_BASE64_LINE_WIDTH CONSTANT PLS_INTEGER := 76 / 4 * 3;
    -- Sent clear Html Email
    procedure send_html_mail (p_sender in varchar2 default null,
    p_recipients in varchar2 default null,
    p_subject in varchar2 default null,
    p_data in varchar2 default null,
    p_mime_type in varchar2 default 'text/html; charset=windows-1255');
    -- Sent Html Email with Attachment
    procedure send_html_mail_attach (p_sender in varchar2 default null,
    p_recipients in varchar2 default null,
    p_subject in varchar2 default null,
    p_data in varchar2 default '<b>áå÷ø èåá òåìí - áãé÷ä</b',
    p_mime_type in varchar2 default 'text/html; charset=windows-1255',
    p_file_name in varchar2 default 'but_choose_file.gif',
    p_file_mime_type in varchar2 default 'application/pdf',
    p_file_URL in varchar2 default 'http://10.172.246.160:7777/i/but_choose_file.gif');
    -- A simple email API for sending email in plain text in a single call.
    -- The format of an email address is one of these:
    -- someone@some-domain
    -- "Someone at some domain" <someone@some-domain>
    -- Someone at some domain <someone@some-domain>
    -- The recipients is a list of email addresses separated by
    -- either a "," or a ";"
    PROCEDURE mail(sender IN VARCHAR2,
              recipients IN VARCHAR2,
              subject IN VARCHAR2,
              message IN VARCHAR2);
    -- Extended email API to send email in HTML or plain text with no size limit.
    -- First, begin the email by begin_mail(). Then, call write_text() repeatedly
    -- to send email in ASCII piece-by-piece. Or, call write_mb_text() to send
    -- email in non-ASCII or multi-byte character set. End the email with
    -- end_mail().
    FUNCTION begin_mail(sender IN VARCHAR2,
              recipients IN VARCHAR2,
              subject IN VARCHAR2,
              mime_type IN VARCHAR2 DEFAULT 'text/plain',
              priority IN PLS_INTEGER DEFAULT NULL)
              RETURN utl_smtp.connection;
    -- Write email body in ASCII
    PROCEDURE write_text(conn IN OUT NOCOPY utl_smtp.connection,
              message IN VARCHAR2);
    -- Write email body in non-ASCII (including multi-byte). The email body
    -- will be sent in the database character set.
    PROCEDURE write_mb_text(conn IN OUT NOCOPY utl_smtp.connection,
                   message IN VARCHAR2);
    -- Write email body in binary
    PROCEDURE write_raw(conn IN OUT NOCOPY utl_smtp.connection,
              message IN RAW);
    -- APIs to send email with attachments. Attachments are sent by sending
    -- emails in "multipart/mixed" MIME format. Specify that MIME format when
    -- beginning an email with begin_mail().
    -- Send a single text attachment.
    PROCEDURE attach_text(conn IN OUT NOCOPY utl_smtp.connection,
                   data IN VARCHAR2,
                   mime_type IN VARCHAR2 DEFAULT 'text/plain',
                   inline IN BOOLEAN DEFAULT TRUE,
                   filename IN VARCHAR2 DEFAULT NULL,
              last IN BOOLEAN DEFAULT FALSE);
    -- Send a binary attachment. The attachment will be encoded in Base-64
    -- encoding format.
    PROCEDURE attach_base64(conn IN OUT NOCOPY utl_smtp.connection,
                   data IN RAW,
                   mime_type IN VARCHAR2 DEFAULT 'application/octet',
                   inline IN BOOLEAN DEFAULT TRUE,
                   filename IN VARCHAR2 DEFAULT NULL,
                   last IN BOOLEAN DEFAULT FALSE);
    -- Send an attachment with no size limit. First, begin the attachment
    -- with begin_attachment(). Then, call write_text repeatedly to send
    -- the attachment piece-by-piece. If the attachment is text-based but
    -- in non-ASCII or multi-byte character set, use write_mb_text() instead.
    -- To send binary attachment, the binary content should first be
    -- encoded in Base-64 encoding format using the demo package for 8i,
    -- or the native one in 9i. End the attachment with end_attachment.
    PROCEDURE begin_attachment(conn IN OUT NOCOPY utl_smtp.connection,
                   mime_type IN VARCHAR2 DEFAULT 'text/plain',
                   inline IN BOOLEAN DEFAULT TRUE,
                   filename IN VARCHAR2 DEFAULT NULL,
                   transfer_enc IN VARCHAR2 DEFAULT NULL);
    -- End the attachment.
    PROCEDURE end_attachment(conn IN OUT NOCOPY utl_smtp.connection,
                   last IN BOOLEAN DEFAULT FALSE);
    -- End the email.
    PROCEDURE end_mail(conn IN OUT NOCOPY utl_smtp.connection);
    -- Extended email API to send multiple emails in a session for better
    -- performance. First, begin an email session with begin_session.
    -- Then, begin each email with a session by calling begin_mail_in_session
    -- instead of begin_mail. End the email with end_mail_in_session instead
    -- of end_mail. End the email session by end_session.
    FUNCTION begin_session RETURN utl_smtp.connection;
    -- Handling the Email Subject Line
    function mimeheader_encode(
    p_str varchar2
    , p_charset varchar2 := 'UTF-8') return varchar2;
    -- Begin an email in a session.
    PROCEDURE begin_mail_in_session(conn IN OUT NOCOPY utl_smtp.connection,
                        sender IN VARCHAR2,
                        recipients IN VARCHAR2,
                        subject IN VARCHAR2,
    --                     mime_type IN VARCHAR2 DEFAULT 'text/plain; charset=windows-1255',
              mime_type IN VARCHAR2 DEFAULT 'text/plain',
                        priority IN PLS_INTEGER DEFAULT NULL);
    -- End an email in a session.
    PROCEDURE end_mail_in_session(conn IN OUT NOCOPY utl_smtp.connection);
    -- End an email session.
    PROCEDURE end_session(conn IN OUT NOCOPY utl_smtp.connection);
    END;
    CREATE OR REPLACE PACKAGE BODY demo_mail_heb IS
    -- Sent clear Html Email
    procedure send_html_mail (p_sender in varchar2 default null,
    p_recipients in varchar2 default null,
    p_subject in varchar2 default null,
    p_data in varchar2 default null,
    p_mime_type in varchar2 default 'text/html; charset=windows-1255')
    Is
    conn utl_smtp.connection;
    BEGIN
    conn := demo_mail_heb.begin_mail(
    sender => p_sender,
    recipients => p_recipients,
    subject => p_subject,
    mime_type => 'text/html; charset=UTF-8');--p_mime_type);
    demo_mail_heb.write_text(
    conn => conn,
    message => p_data);
    demo_mail_heb.end_mail( conn => conn );
    END;
    -- Sent Html Email with Attachment
    procedure send_html_mail_attach (p_sender in varchar2 default null,
    p_recipients in varchar2 default null,
    p_subject in varchar2 default null,
    p_data in varchar2 default '<b>áå÷ø èåá òåìí - áãé÷ä</b',
    p_mime_type in varchar2 default 'text/html; charset=windows-1255',
    p_file_name in varchar2 default 'but_choose_file.gif',
    p_file_mime_type in varchar2 default 'application/pdf',
    p_file_URL in varchar2 default 'http://10.172.246.160:7777/i/but_choose_file.gif')
    is
    conn utl_smtp.connection;
    req utl_http.req;
    resp utl_http.resp;
    data RAW(200);
    v_mime_type varchar2(32767):=demo_mail.MULTIPART_MIME_TYPE;
    begin
    conn := demo_mail_heb.begin_mail(
    sender => p_sender,
    recipients => p_recipients,
    subject => p_subject,
    mime_type => v_mime_type);
    demo_mail_heb.attach_text(
    conn => conn,
    data => p_data,
    mime_type => 'text/html');
    demo_mail_heb.begin_attachment(
    conn => conn,
    mime_type => p_file_mime_type,
    inline => TRUE,
    filename => p_file_name,
    transfer_enc => 'base64');
    -- In writing Base-64 encoded text following the MIME format below,
    -- the MIME format requires that a long piece of data must be splitted
    -- into multiple lines and each line of encoded data cannot exceed
    -- 80 characters, including the new-line characters. Also, when
    -- splitting the original data into pieces, the length of each chunk
    -- of data before encoding must be a multiple of 3, except for the
    -- last chunk. The constant demo_mail_heb.MAX_BASE64_LINE_WIDTH
    -- (76 / 4 * 3 = 57) is the maximum length (in bytes) of each chunk
    -- of data before encoding.
    req := utl_http.begin_request(p_file_URL);
    resp := utl_http.get_response(req);
    BEGIN
    LOOP
    utl_http.read_raw(resp, data, demo_mail_heb.MAX_BASE64_LINE_WIDTH);
    demo_mail_heb.write_raw(
    conn => conn,
    message => utl_encode.base64_encode(data));
    END LOOP;
    EXCEPTION
    WHEN utl_http.end_of_body THEN
    utl_http.end_response(resp);
    END;
    demo_mail_heb.end_attachment( conn => conn );
    demo_mail_heb.end_mail( conn => conn );
    end;
    -- Return the next email address in the list of email addresses, separated
    -- by either a "," or a ";". The format of mailbox may be in one of these:
    -- someone@some-domain
    -- "Someone at some domain" <someone@some-domain>
    -- Someone at some domain <someone@some-domain>
    FUNCTION get_address(addr_list IN OUT VARCHAR2) RETURN VARCHAR2 IS
    addr VARCHAR2(256);
    i pls_integer;
    FUNCTION lookup_unquoted_char(str IN VARCHAR2,
    chrs IN VARCHAR2) RETURN pls_integer AS
    c VARCHAR2(5);
    i pls_integer;
    len pls_integer;
    inside_quote BOOLEAN;
    BEGIN
    inside_quote := false;
    i := 1;
    len := length(str);
    WHILE (i <= len) LOOP
    c := substr(str, i, 1);
    IF (inside_quote) THEN
    IF (c = '"') THEN
    inside_quote := false;
    ELSIF (c = '\') THEN
    i := i + 1; -- Skip the quote character
    END IF;
    GOTO next_char;
    END IF;
    IF (c = '"') THEN
    inside_quote := true;
    GOTO next_char;
    END IF;
    IF (instr(chrs, c) >= 1) THEN
    RETURN i;
    END IF;
    <<next_char>>
    i := i + 1;
    END LOOP;
    RETURN 0;
    END;
    BEGIN
    addr_list := ltrim(addr_list);
    i := lookup_unquoted_char(addr_list, ',;');
    IF (i >= 1) THEN
    addr := substr(addr_list, 1, i - 1);
    addr_list := substr(addr_list, i + 1);
    ELSE
    addr := addr_list;
    addr_list := '';
    END IF;
    i := lookup_unquoted_char(addr, '<');
    IF (i >= 1) THEN
    addr := substr(addr, i + 1);
    i := instr(addr, '>');
    IF (i >= 1) THEN
    addr := substr(addr, 1, i - 1);
    END IF;
    END IF;
    RETURN addr;
    END;
    -- Write a MIME header
    PROCEDURE write_mime_header(conn IN OUT NOCOPY utl_smtp.connection,
    name IN VARCHAR2,
    value IN VARCHAR2) IS
    BEGIN
    -- utl_smtp.write_data(conn, name || ': ' || value || utl_tcp.CRLF);
    utl_smtp.write_raw_data(conn, UTL_RAW.CAST_TO_RAW(name || ': ' ||value || utl_tcp.CRLF));
    END;
    -- Mark a message-part boundary. Set <last> to TRUE for the last boundary.
    PROCEDURE write_boundary(conn IN OUT NOCOPY utl_smtp.connection,
    last IN BOOLEAN DEFAULT FALSE) AS
    BEGIN
    IF (last) THEN
    utl_smtp.write_data(conn, LAST_BOUNDARY);
    ELSE
    utl_smtp.write_data(conn, FIRST_BOUNDARY);
    END IF;
    END;
    PROCEDURE mail(sender IN VARCHAR2,
    recipients IN VARCHAR2,
    subject IN VARCHAR2,
    message IN VARCHAR2) IS
    conn utl_smtp.connection;
    BEGIN
    conn := begin_mail(sender, recipients, subject);
    write_text(conn, message);
    end_mail(conn);
    END;
    FUNCTION begin_mail(sender IN VARCHAR2,
    recipients IN VARCHAR2,
    subject IN VARCHAR2,
    mime_type IN VARCHAR2 DEFAULT 'text/plain',
    priority IN PLS_INTEGER DEFAULT NULL)
    RETURN utl_smtp.connection IS
    conn utl_smtp.connection;
    BEGIN
    conn := begin_session;
    begin_mail_in_session(conn, sender, recipients, subject, mime_type,
    priority);
    RETURN conn;
    END;
    PROCEDURE write_text(conn IN OUT NOCOPY utl_smtp.connection,
    message IN VARCHAR2) IS
    BEGIN
    utl_smtp.write_raw_data(conn, utl_raw.cast_to_raw(CONVERT(message,'IW8ISO8859P8')));
    -- utl_smtp.write_raw_data(conn, utl_raw.cast_to_raw(message));
    END;
    PROCEDURE write_mb_text(conn IN OUT NOCOPY utl_smtp.connection,
    message IN VARCHAR2) IS
    BEGIN
    utl_smtp.write_raw_data(conn, utl_raw.cast_to_raw(message));
    END;
    PROCEDURE write_raw(conn IN OUT NOCOPY utl_smtp.connection,
    message IN RAW) IS
    BEGIN
    utl_smtp.write_raw_data(conn, message);
    END;
    PROCEDURE attach_text(conn IN OUT NOCOPY utl_smtp.connection,
    data IN VARCHAR2,
    mime_type IN VARCHAR2 DEFAULT 'text/plain',
    inline IN BOOLEAN DEFAULT TRUE,
    filename IN VARCHAR2 DEFAULT NULL,
    last IN BOOLEAN DEFAULT FALSE) IS
    BEGIN
    begin_attachment(conn, mime_type, inline, filename);
    write_text(conn, data);
    end_attachment(conn, last);
    END;
    PROCEDURE attach_base64(conn IN OUT NOCOPY utl_smtp.connection,
    data IN RAW,
    mime_type IN VARCHAR2 DEFAULT 'application/octet',
    inline IN BOOLEAN DEFAULT TRUE,
    filename IN VARCHAR2 DEFAULT NULL,
    last IN BOOLEAN DEFAULT FALSE) IS
    i PLS_INTEGER;
    len PLS_INTEGER;
    BEGIN
    begin_attachment(conn, mime_type, inline, filename, 'base64');
    -- Split the Base64-encoded attachment into multiple lines
    i := 1;
    len := utl_raw.length(data);
    WHILE (i < len) LOOP
    IF (i + MAX_BASE64_LINE_WIDTH < len) THEN
    utl_smtp.write_raw_data(conn,
    utl_encode.base64_encode(utl_raw.substr(data, i,
    MAX_BASE64_LINE_WIDTH)));
    ELSE
    utl_smtp.write_raw_data(conn,
    utl_encode.base64_encode(utl_raw.substr(data, i)));
    END IF;
    utl_smtp.write_data(conn, utl_tcp.CRLF);
    i := i + MAX_BASE64_LINE_WIDTH;
    END LOOP;
    end_attachment(conn, last);
    END;
    PROCEDURE begin_attachment(conn IN OUT NOCOPY utl_smtp.connection,
    mime_type IN VARCHAR2 DEFAULT 'text/plain',
    inline IN BOOLEAN DEFAULT TRUE,
    filename IN VARCHAR2 DEFAULT NULL,
    transfer_enc IN VARCHAR2 DEFAULT NULL) IS
    BEGIN
    write_boundary(conn);
    write_mime_header(conn, 'Content-Type', mime_type);
    IF (filename IS NOT NULL) THEN
    IF (inline) THEN
    write_mime_header(conn, 'Content-Disposition',
    'inline; filename="'||filename||'"');
    ELSE
    write_mime_header(conn, 'Content-Disposition',
    'attachment; filename="'||filename||'"');
    END IF;
    END IF;
    IF (transfer_enc IS NOT NULL) THEN
    write_mime_header(conn, 'Content-Transfer-Encoding', transfer_enc);
    END IF;
    utl_smtp.write_data(conn, utl_tcp.CRLF);
    END;
    PROCEDURE end_attachment(conn IN OUT NOCOPY utl_smtp.connection,
    last IN BOOLEAN DEFAULT FALSE) IS
    BEGIN
    utl_smtp.write_data(conn, utl_tcp.CRLF);
    IF (last) THEN
    write_boundary(conn, last);
    END IF;
    END;
    PROCEDURE end_mail(conn IN OUT NOCOPY utl_smtp.connection) IS
    BEGIN
    end_mail_in_session(conn);
    end_session(conn);
    END;
    FUNCTION begin_session RETURN utl_smtp.connection IS
    conn utl_smtp.connection;
    BEGIN
    -- open SMTP connection
    conn := utl_smtp.open_connection(smtp_host, smtp_port);
    utl_smtp.helo(conn, smtp_domain);
    RETURN conn;
    END;
    -- Handling the Email Subject Line
    function mimeheader_encode(
    p_str varchar2
    , p_charset varchar2 := 'UTF-8') return varchar2 is
    l_str varchar2(2000);
    begin
    l_str:=utl_raw.cast_to_varchar2(utl_encode.quoted_printable_encode(utl_raw.cast_to_raw(p_str)));
    l_str:=replace(l_str,'='||chr(13)||chr(10),''); --unfold the data
    l_str:=replace(l_str,'?','=3f'); --quote question marks
    l_str:=replace(l_str,' ','=20'); --quote spaces
    l_str:='=?'||p_charset||'?Q?'||l_str||'?='; -- add prefix and suffix
    return l_str;
    end;
    PROCEDURE begin_mail_in_session(conn IN OUT NOCOPY utl_smtp.connection,
    sender IN VARCHAR2,
    recipients IN VARCHAR2,
    subject IN VARCHAR2,
    mime_type IN VARCHAR2 DEFAULT 'text/plain',
    -- mime_type IN VARCHAR2 DEFAULT 'text/plain; charset=windows-1255',
    priority IN PLS_INTEGER DEFAULT NULL) IS
    my_recipients VARCHAR2(32767) := recipients;
    my_sender VARCHAR2(32767) := sender;
    BEGIN
    -- Specify sender's address (our server allows bogus address
    -- as long as it is a full email address ([email protected]).
    utl_smtp.mail(conn, get_address(my_sender));
    -- Specify recipient(s) of the email.
    WHILE (my_recipients IS NOT NULL) LOOP
    utl_smtp.rcpt(conn, get_address(my_recipients));
    END LOOP;
    -- Start body of email
    utl_smtp.open_data(conn);
    -- Set "From" MIME header
    write_mime_header(conn, 'From', sender);
    -- Set "To" MIME header
    write_mime_header(conn, 'To', recipients);
    -- Set "Content-Type" MIME header
    write_mime_header(conn, 'Content-Type', mime_type);
    -- write_mime_header(conn, 'Content-Type', 'text/html; charset=UTF-8');
    -- Set "Subject" MIME header
    -- write_mime_header(conn, 'Subject', subject);
    -- write_mime_header(conn, 'Subject', CONVERT(subject,'IW8ISO8859P8'));
    write_mime_header(conn, 'Subject',mimeheader_encode(p_str => subject,p_charset => 'UTF-8'));
    -- write_mime_header(conn, 'Subject',CONVERT(subject,'IW8MSWIN1255'));
    -- Set "X-Mailer" MIME header
    write_mime_header(conn, 'X-Mailer', MAILER_ID);
    -- Set priority:
    -- High Normal Low
    -- 1 2 3 4 5
    IF (priority IS NOT NULL) THEN
    write_mime_header(conn, 'X-Priority', priority);
    END IF;
    -- Send an empty line to denotes end of MIME headers and
    -- beginning of message body.
    utl_smtp.write_data(conn, utl_tcp.CRLF);
    IF (mime_type LIKE 'multipart/mixed%') THEN
    write_text(conn, 'This is a multi-part message in MIME format.' ||
    utl_tcp.crlf);
    END IF;
    END;
    PROCEDURE end_mail_in_session(conn IN OUT NOCOPY utl_smtp.connection) IS
    BEGIN
    utl_smtp.close_data(conn);
    END;
    PROCEDURE end_session(conn IN OUT NOCOPY utl_smtp.connection) IS
    BEGIN
    utl_smtp.quit(conn);
    END;
    END;

  • Need help in implementing a note

    Gurus ,
      i need your help in implemnting the SAP NOTE
    "873422 - Error when sending an e-mail"
    I am not suer how to proceed to implement the correction speified in that note .
    it would be of great help if any body can explain me in brief  to implement atleast one correction in that note

    Hi Susin,
    The first thing for Note 873422,
    "You have created e-mails from Audit Management. The system automatically attaches a link to the display of the audit object being sent. When you send an e-mail via SAPconnect, the following error occurs: XS 829 Internal error: SO_OBJECT_MIME_GET Exception: 2."
    Are you getting this symptom in your system? and you want to apply the correction??
    After applying the correction, if the prerequisite mentioned in note 530932 is not met during sending mail.. then
    simply the link will not be attached. but mail will be sent.
    you have to apply the correction of the note using SNOTE or manually apply note by download/upload.
    For how to apply a note using SNOTE you can follow the help guide
    http://help.sap.com/saphelp_nw70/helpdata/EN/b8/3cf839fd35384de10000000a11402f/frameset.htm
    Regards,
    Debasis.

  • Attached image is null

    <?xml version="1.0" encoding="UTF-8"?>
    <definitions xmlns="http://schemas.xmlsoap.org/wsdl/"
         xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
         xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
         xmlns:soapbind="http://schemas.xmlsoap.org/wsdl/soap/"
         xmlns:tns="http://www.example.org/SOAPAttReceiverWithMessage/"
         xmlns:xsd="http://www.w3.org/2001/XMLSchema"
         targetNamespace="http://www.example.org/SOAPAttReceiverWithMessage/">
         <types>
              <xsd:schema
                   targetNamespace="http://www.example.org/SOAPAttReceiverWithMessage/"
                   xmlns:tns="http://www.example.org/SOAPAttReceiverWithMessage/"
                   xmlns:xsd="http://www.w3.org/2001/XMLSchema">
                   <xsd:element name="InfoMessage" type="xsd:string" />
              </xsd:schema>
         </types>
         <message name="imageMsg">
              <part element="tns:InfoMessage" name="body" />
              <part name="image" type="xsd:hexBinary" />
         </message>
         <message name="empty" />
         <portType name="AttachmentWithMessage">
              <operation name="sendImageAndMessage">
                   <input message="tns:imageMsg" />
                   <output message="tns:empty" />
              </operation>
         </portType>
         <binding name="AttachmentWithMessageBinding"
              type="tns:AttachmentWithMessage">
              <soap:binding style="rpc"
                   transport="http://schemas.xmlsoap.org/soap/http" />
              <operation name="sendImageAndMessage">
                   <soap:operation soapAction="" />
                   <input>
                        <soap:body parts="body" use="literal" />
                        <mime:multipartRelated>
                             <mime:part>
                                  <mime:content part="image" type="image/gif" />
                             </mime:part>
                        </mime:multipartRelated>
                   </input>
                   <output>
                        <soap:body use="literal" />
                   </output>
              </operation>
         </binding>
         <service name="AttachmentWithMessageService">
              <port binding="tns:AttachmentWithMessageBinding"
                   name="AttachmentWithMessage">
                   <soap:address
                        location="URL" />
              </port>
         </service>
    </definitions>Endpoint generated form WSDL
    public class AttachmentWithMessageBindingImpl implements org.example.www.AttachmentWithMessage{
        public void sendImageAndMessage(java.lang.String body, java.awt.Image image) throws java.rmi.RemoteException {}
             Client
      Name bodyName = soapFactory.createName(
                      "sendImageAndMessage", "tns",
                      "http://www.example.org/SOAPAttReceiverWithMessage/");
                    SOAPBodyElement bodyElement =
                      body.addBodyElement(bodyName);
                    Name name = soapFactory.createName("InfoMessage");
                    SOAPElement info =
                      bodyElement.addChildElement(name);
                    info.addTextNode("This is a info message!");
                    AttachmentPart attachment = message.createAttachmentPart();
                    URL url = new URL("file:///C:/temp/pic.gif");
                    URLDataSource fds = new URLDataSource(url);
                    DataHandler dataHandler = new DataHandler(fds);
                    AttachmentPart attachmentPart =
                      message.createAttachmentPart(dataHandler);
                    attachment.setContentId("image");
                    attachment.setContentType("image/gif");
                    message.addAttachmentPart(attachmentPart);
                    URL endpoint = new URL
                      ("URL");
                   // SOAPMessage response =
                      connection.call(message, endpoint);
                    connection.close();I get the body part right but image is null. SOAP message seems to have this image attached but when I try to access it at the enpoint it's null.
    SOAP message:
    ------=_Part_0_394663814.1176981061039
    Content-Type: text/xml; charset=UTF-8
    Content-Transfer-Encoding: binary
    Content-Id: <841848929844.1176981061039.***>
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><soapenv:Body><tns:sendImageAndMessage xmlns:tns="http://www.example.org/SOAPAttReceiverWithMessage/"><InfoMessage>This is a info message!</InfoMessage></tns:sendImageAndMessage></soapenv:Body></soapenv:Envelope>
    ------=_Part_0_394663814.1176981061039
    Content-Type: image/gif
    Content-Transfer-Encoding: binary
    Content-Id: <83287838504.1176981059055.***>
    GIF89a�h�Any suggestions?

    try {
                   MessageContext context = MessageContext.getCurrentThreadsContext();
                   SOAPMessageContext soapContext = (SOAPMessageContext)context;
                   SOAPMessage msg = soapContext.getMessage();
                   SOAPPart soapPart =     msg.getSOAPPart();
                   SOAPEnvelope envelope = soapPart.getEnvelope();
                   Iterator i = msg.getAttachments();
                   while(i.hasNext())
                        System.out.println("Attachment");
                        AttachmentPart ap = (AttachmentPart)i.next();
                        System.out.println(ap.getContentId());
                        System.out.println(ap.getContentType());
                        System.out.println(ap.getContentLocation());
                        System.out.println(ap.getSize());
                        Object oo = ap.getContent();
                        if(oo==null){
                             System.out.println("oo is nul");
                        DataHandler dh = (DataHandler)ap.getDataHandler();
                        if(dh==null){
                             System.out.println("dh is null");
                        else{
                             Image o = (Image)dh.getContent();
                   }When I try to cast DataHandler.getContent() to java awt.Image I get following exception:
    com.ibm.ws.webservices.engine.attachments.ManagedMemoryDataSource$Instream incompatible with java.awt.Image
    [23.4.2007 16:37:05:862 EEST] 0000002e SystemErr     R java.lang.ClassCastException: com.ibm.ws.webservices.engine.attachments.ManagedMemoryDataSource$Instream incompatible with java.awt.Image
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at org.example.www.AttachmentWithMessageBindingImpl.sendImageAndMessage(AttachmentWithMessageBindingImpl.java:65)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at java.lang.reflect.Method.invoke(Method.java:615)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.dispatchers.java.JavaDispatcher.invokeMethod(JavaDispatcher.java:178)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.dispatchers.java.JavaDispatcher.invokeOperation(JavaDispatcher.java:141)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.dispatchers.SoapRPCProcessor.processRequestResponse(SoapRPCProcessor.java:447)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.dispatchers.SoapRPCProcessor.processMessage(SoapRPCProcessor.java:412)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.dispatchers.BasicDispatcher.processMessage(BasicDispatcher.java:134)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.dispatchers.java.SessionDispatcher.invoke(SessionDispatcher.java:204)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.PivotHandlerWrapper.invoke(PivotHandlerWrapper.java:227)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.handlers.jaxrpc.JAXRPCHandler.invoke(JAXRPCHandler.java:152)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.handlers.WrappedHandler.invoke(WrappedHandler.java:64)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.PivotHandlerWrapper.invoke(PivotHandlerWrapper.java:227)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.PivotHandlerWrapper.invoke(PivotHandlerWrapper.java:227)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.WebServicesEngine.invoke(WebServicesEngine.java:332)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.transport.http.WebServicesServlet.doPost(WebServicesServlet.java:736)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at javax.servlet.http.HttpServlet.service(HttpServlet.java:763)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webservices.engine.transport.http.WebServicesServletBase.service(WebServicesServletBase.java:341)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:966)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:478)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:463)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3129)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:238)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1433)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:93)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:465)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:394)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(HttpInboundLink.java:290)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.sendToDiscriminators(NewConnectionInitialReadCallback.java:214)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.complete(NewConnectionInitialReadCallback.java:113)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:152)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:213)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(AbstractAsyncFuture.java:195)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:741)
    [23.4.2007 16:37:05:893 EEST] 0000002e SystemErr     R      at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863)
    [23.4.2007 16:37:05:909 EEST] 0000002e SystemErr     R      at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1510)When sending I print size of the attachment
    Attachment size = 45233
    Size is same when receiving message at server but still it's null.

  • Receiving, opening, saving attachment​s WARNING long post

    In some ways, this post is more of a reminder to myself on how to deal with attachments that I've discovered so far and hopefully it will help some other confused souls. I'm betting that like most people on this forum, your interest in the Playbook is partly motivated by how you can quickly and easily access files on the run to review them and edit them minimally and quickly (oops! forgot to change the boss' title in the memo now!) without resorting to hauling out a laptop, waiting for it to start, load the relevant office program, and then hoping your hotel wifi is strong and stable enough to actually load up a bloated email client to download far too many attachments. If that's your circumstances are like mine, then the PB is clearly a work in progress. I thought that Apple's iPad method of dealing with document transfers was crippled at best; the PB is a quest in hide-and-seek.
    Transferring media files (photos, movies, etc.). If you use Windows, I'm guessing you're doing okay. If you use a Mac like me, the BB Desktop will not work for such transfers. You can use wifi to bulk transfer media files from your Mac to the PB, but you lose the rich context (playlists, etc.) that you probably want.
    Opening attachments in Mail within Bridge. This one confuses me, but I suppose it works best for the corporate world - maybe. If I open an attachment from an email in the PB Bridge from within Mail, I could select an attachment and tap to open it. The relevant app (Reader, sheet to go, word to go, etc.) opens up a new window and the document can be read. At this point in the RIM life cycle, any documents within Bridge are read-only and cannot be saved/edited, which of course defeats any aspirations of on-the-fly editing. Nonetheless, they are viewable and gloriously so. But it was not obvious to me where the documents were now. If I wanted to, say, review them later, where would I find them? The most rational place I thought they would be would be the Bridge Files icon. However, if I selected Playbook under Bridge Files, there did not seem to be anything, and if I selected BlackBerry smartphone, it was not obvious either. By chance, I muddled through and discovered that under the smartphone choice, if I drilled down through my SD card directory to BlackBerry to documents to Bridge (ah! that's new!) subfolders, I would find all my downloaded documents in this new Bridge folder which is supposedly on my smartphone. Distressingly, I cannot find this same subfolder "Bridge" on the SD card on the smartphone itself.
    But this is the where we enter another dimension however! All of the above (2) ONLY seems to apply to emails sent to my GMail account that my BlackBerry - and therefore my PB - is also set up to receive within Mail in Bridge: given that I'm not an IT adminstrator, I'll just call them the non-corporate emails. If I open up an attachment from a message in Mail within Bridge that was sent through my usual corporate email system (in this case, Lotus Notes - yet another story), then the attachment ends up in SD card directory to BlackBerry to documents, but does not go into Bridge. I lack the knowledge or wisdom to fathom why this is different, other than it probably has something to do with the corporate side of things. 
    Opening attachments from Webmail (e.g. GMail). This one is also a bit bizarre. Although not very easy to find, at least all the attachments from (2) and (3) ended up in almost the same places on my smartphone SD card. But you cannot edit them.  So what if I opened up via the web browser? GMail works quite well actually. When I tapped on an attachment to open it in GMail, it would bring me to a new pane and ask me to save it (Save "1"). It does not necessarily open it however and sometimes I would just get a new blank window. But if I swipe down from the top, I could see the downloads option, and choosing that would show me the attached document and an Open button. Opening it would load the document using the relevant app (e.g. Word to Go) and swiping down gave me another save (yes!) option (Save "2"). However, I had no idea where the attachment was saved. It does not appear under Media, any Bridge folder, etc. Assuming the attachment file type is associated with the app however, if you now open, say, Word-to-Go, well, there it is (finally!). So, the bizzarre thing is that the first save (Save "1") that you are prompted with does not seem to actually save it: only after the relevant app loads it and then you save it again (Save "2") does the attachment seem to actually get transferred to the Playbook's internal memory (somewhere). I cannot figure out the reason why you have to go through this double step. But at least now I can edit them. So maybe the solution is to mirror all my corporate emails to another service like GMail or Hotmail? (I can hear the collective gasps of the security minded types!)
    Opening attachments from Webmail (e.g., GMail) within the Bridge Browser. This is maybe the ultimate compromise and combination of the above, and perhaps the situation most of us want to know about when we're on the go, get that ever important email about what was needed yesterday, don't have wifi access, but need to edit the attachment and cannot do it within the regular mail within Bridge. Dismally, this one is a fail - I get the error message "Bridge Browser: Cannot download corporate files." 
    After fumbling my way through an iPad and pretty much abandoning it for my workflow (although it is very good for other applications), I thought the Playbook would address almost of my needs, particularly since I've used a BlackBerry for the last six years. Personally, I think the PB hardware is fantastic, the form factor is great, and I do not care for or need 1000's of useless and trivial apps, but the implementation of what I consider core functionality is mediocre at best. I'm an academic - I'd grade the Playbook a C- (maybe even a D+ (ouch!) if I was in a grumpy mood).
    In the interests of fairness, I recognize that some of the issues may simply be the way my corporate parent runs its business. I toil away under Lotus Notes and use a BlackBerry Bold, OS5, Rogers network, and a three year MacBook Pro.
    If anybody has found other solutions or I've simply done something wrong, I'd love to hear. Otherwise, my abode will likely not be this Playbook's forever home.

    Hi fochtk... you're welcome (I think! this seems unnecessarily confusing!). I think you're referring to my points (2) and (3) from my original post. In summary, this is what I THINK is happening.
    On my BlackBerry Bold 9700, I have two email accounts, my corporate Lotus account, and my GMail account. There is one universal desktop that gathers both incoming emails into one so that I can view all messages at the same time. I imagine that the corporate server for this universal desktop therefore also have all these same messages because all the messages (GMail and Lotus) then show up in Mail via Bridge on my PB.
    A. When in Bridge - Mail I open up an attachment in a mail that was received by my corporate Lotus account, the documents show up on my phone's SD card (I think you mean the memory card, not the SIM card for telecommunications). If I check my Playbook under Bridge Files -> Phone Icon -> BlackBerry/SDCard -> Documents, the attachments are there, and if I check my file manager on my phone, the same attachments are listed in the same subfolder. Interestingly, I was given the option to download them too.
    B. When I open up an attachment in a mail that was received initially by my GMail account, the documents are not given the option to download. However, when I go to Bridge Files -> Phone Icon -> BlackBerry/SDCard -> Documents -> Bridge, the attachments from this GMail destined message are there! Weird, because I didn't create a Bridge subfolder on my phone's SD card, nor can I find a Bridge subfolder on the phone itself.
    SORRY. I stand corrected. I just went into Bridge - Mail to double check and guess what... ALL of my email attachments no matter what account they were sent to originally (Lotus or GMail) if they are accessed through Bridge get dumped into this Bridge subfolder that is supposedly located on my phone's SD card (situation B). Maybe situation A was for when I downloaded the attachment to the phone first: I've gone back and forth with this so many times now...
    Maybe this Bridge subfolder is a hidden folder tied to your phone so that if you lose your Playbook attachments cannot be accessed? But there seems to be no options to delete these downloaded files. UPDATE! Yes, I should have checked sooner. When you are accessing your phone, use the menu button to select "Show Hidden". It then displays the greyed out Bridge subfolder under Documents and you can then manipulate (e.g., delete) your files from there. This would make sense so that your files are as secure as possible via your phone. Still can't edit the attachments though... 
    Hope this helps...

  • Browse and attach code in JSP

    hi everyone,
    in my jsp i have to implement a functionality where user clicks browse button and selects a file and then attaches it .. how do i implement it ... are there any ready made functions

    <form action="/context/servlet/myservlet" enctype="multipart/form-data">
    File: <input type="file" name="file"/><br>
    <input type="submit" value="Upload"/>
    </form>The enctype parameter tells the client that it needs to build a multipart request (one that will contain text and binary data). This is required.
    The input type="file" element is the actual file browsing mechanism.
    Next download the O'Reilly fileupload package ( http://servlets.com/cos/ ) and use it in your servlet that receives the request. The MultiPartRequest I believe is what you need.
    Once you get there, if you need more help post back.

  • Windows 7 Pro/Outlook 2007/SharePoint Foundation 2007? .eml files open as attachment in outlook

    Here is the issue.
    I am running Windows 7 Pro with Office 2007.
    I attempt to open an email from sharepoint.  The email becomes an attachment to a new mail message from outlook 2007.
    When I attempt to open the same email from command line, it opens correctly.
    I have checked registry entries, and they all seem to point to the right places.
    I have set Outlook as the default E-mail program, as well as assigned the .eml files as defaulting to outlook.
    I have ran the microsoft fix, and manually implemented the fix after it didn't work, both to no avail.
    I need a solution for this, I can't believe Microsoft would have such an issue with compatibility with their own programs.
    If anyone has some insight, it is welcomed with open arms.
    I am unsure which forum to place this topic, since it covers so many microsoft issues/programs, so if this is located in the wrong place, please move it for me.
    I thank you all in advance for your assistance in this matter.

    Hi,
    According to your description, I suggest to ask Office Forum further help:
    http://social.technet.microsoft.com/Forums/en-US/category/officeitpro
    The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and
    other partners who read the forums regularly can either share their knowledge or learn from your interaction with us.  Thank you for your understanding.
    Regards,
    Leo  
    Huang
    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

  • Memory leak in JSpinner implementation (maybe others?)

    Hi,
    I am developing an application using Java and Swing, and have run into some problems with memory leaks. After examining the source code and making an example program (provided below), I can only come to the conclusion that there is a bug in the implementation of JSpinner in Sun Java 1.6.0_03.
    If one uses a custom model with the JSpinner, it attaches itself as a listener to the model. However, it never removes the listening connection, even if the model is changed. This causes the JSpinner to be kept in memory as long as the model exists, even if all other references to the component have been removed.
    An example program is available at http://eddie.dy.fi/~sampo/ModelTest.java . It is a simple swing program that has the JSpinner and two buttons, the first of which writes to stdout the listeners of the original model and the second changes the spinner model to a newly-created model. A sample output is below:
    Running on 1.6.0_03 from Sun Microsystems Inc.
    Listeners before connecting to JSpinner:
      Model value is 0, 0 listeners connected:
    Listeners after connecting to JSpinner:
      Model value is 0, 2 listeners connected:
      1: interface javax.swing.event.ChangeListener
      2: javax.swing.JSpinner$ModelListener@9971ad
    Listeners now:
      Model value is 8, 2 listeners connected:
      1: interface javax.swing.event.ChangeListener
      2: javax.swing.JSpinner$ModelListener@9971ad
    Changing spinner model.
    Listeners now:
      Model value is 8, 2 listeners connected:
      1: interface javax.swing.event.ChangeListener
      2: javax.swing.JSpinner$ModelListener@9971adThis shows that even though the model of the JSpinner has been changed, it still listens to the original model. I haven't looked at other components whether they retain connections to the old models as well.
    In my case, I have an adaptor-model which provides a SpinnerModel interface to the actual data. The adaptor is implemented so that it listens to the underlying model only when it itself is being listened to. If the JComponents using the model were to remove the listening connections, it, too, would be automatically garbage-collected. However, since JSpinner does not remove the connections, the adaptor also continues to listen to the underlying model, and neither can be garbage-collected.
    All in all, the listener-connections seem to be a very easy place to make memory leaks in Java and especially in Swing. However, as I see it, it would be a simple matter to make everything work automatically with one simple rule: Listen to the models only when necessary.
    If a component is hidden (or alternatively has no contact to a parent JFrame or equivalent), it does not need to listen to the model and should remove the connections. When the component is again set visible (or connected to a frame) it can re-add the connections and re-read the current model values just as it does when initializing the component. Similarly, any adaptor-models should listen to the underlying model only when it itself is being listened to.
    If the components were implemented in this way, one could simply remove a component from the frame and throw it away, and automatically any listener-connections will be removed and it can be garbage-collected. Similarly any adaptor-models are collected when they are no longer in use.
    Changing the API implementation in this way would not require any changes to applications, as the only thing that changes are the listener-connections. Currently used separate connection-removing methods should still work, though they would be unnecessary any more. The API would look exactly the same from the view of an application programmer, only that she would not need to care about remnant listening connections. (As far as I can tell, the current API specification would allow the API to be implemented as described above, but it should of course require it to be implemented in such a way.)
    Am I missing something, or is there some valid reason why the API is not implemented like this?
    PS. I'm new to these forums, so if there is a better place to post these reports, please tell me. Thanks.

    Another cognition: It's the following code, that causes the memory to be accumulated:
    obj = m_orb.resolve_initial_references("NameService");
    ctx = NamingContextExtHelper.narrow(obj);For the first 4 calls to this code the memory usage of the nameservice is unchanged. From the 5th to the 8th call, it's increased by approx. 10KB per call. And thenceforward (beginning with the 9th call) it's increasing by approx. 10MB.
    What's going wrong here?

Maybe you are looking for

  • Lack of email sync with Outlook may result in returned BB Classic

    Our company president (who is responsible for 15 companies worldwide) recently got a BB Classic and we were extremely disappointed to find a lack of either an "auto-bcc on send" option or a way to sync her email in the hub to Outlook 2013. I was led

  • How To Configure Oracle BPM 11g Process Portal on Oracle WebCenter Spaces

    After setting the file process-portal-install.properties and have set the path environment variable to the ANT. When i execute a command ant -f install.xml i can see the next error [exec] Updating deployment targets for the datasources... [exec] This

  • Will FCP Suite work OK on the dual intel iMac G5 ?

    We are getting ready to open a new digital video classroom for up to 26 students. Each student will have a G5, NTSC monitor, firewire capture device of some sort, and sound I/O to quality sound system. Anyone have any experiences or insight to using

  • Save as- for Dummies (Numbers version)

    Here is a clean way to retrieve Save As… in Numbers. --(SCRIPT Numbers_save_a_copy] Enregistrer le script en tant que Script : Numbers_save_a_copy.scpt déplacer le fichier créé dans le dossier <VolumeDeDémarrage>:Utilisateurs:<votreCompte>:Bibliothèq

  • Server 2008 R2 Powershell version 4 cannot use Get-Net* (anything) commands

    Brand new to PS here. I have a new install of 2008R2 and have updated to Powershell 4 by installing Windows Management Framework 4.0. The system has DotNET 4.5.1 on it as well. I am trying to run a script for setting IP which is part of the example s