Skip to Content

To send an attachment excel sheet from program with readonly workbook.?

Dear All,

We have a requirement in which we need to send an excel sheet as an attachment( internal table to excel ) as readonly.

Sending and internal Table as excel sheet is done and making it as an attchment in a mail has been accomplished.

Now our requirement is to make the attched excel sheet read only(i.e the users getting the mails should not be in aposition to edit any cells of the worksheet.

The mail can be sent from any user. Please help.

Thanks in advance,

Regards,

Sai.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Jul 30, 2009 at 12:56 PM

    Hi,

    You could use protection on the whole worksheet.

    In Excel

    Tools

    Protection

    Protect WorkSheet

    or

    There is another option,

    With this function module you can make file non-transferrable, you can't make it read only with this function module.

    Pass RECEIVERS-NO_FORWARD = 'X' in SO_NEW_DOCUMENT_ATT_SEND_API1 function module.

    with regards,

    Mamta Kumari

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jul 31, 2009 at 03:28 AM

    Hi,

    Refer to the following code:

    lv_doc_data-priority = '1'.

    • Populate the subject/generic message attributes

    lv_doc_data-obj_langu = sy-langu.

    lv_doc_data-obj_name = 'SAPRPT'.

    lv_doc_data-obj_descr = 'Find Inactive PU/DU '.

    lv_doc_data-sensitivty = 'F'.

    lv_doc_data-NO_CHANGE = 'X'.

    whan the parameter NO_CHANGE is set to 'X'. that means document cannot be changed.

    now call the FM.

    CALL FUNCTION 'SO_DOCUMENT_SEND_API1'

    EXPORTING

    document_data = lv_doc_data

    sender_address = lv_sender_address

    sender_address_type = lv_sender_address_type

    commit_work = 'X'

    TABLES

    packing_list = it_packing_list

    contents_txt = it_messages

    receivers = it_receivers.

    Revert back in any query. hope it helps.

    Regards,

    Rajesh Kumar

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Feb 01, 2010 at 11:00 AM

    not resolved but has to close as my open questions are more

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.