Error while opening an attached FI Document in transaction FB03.
Hi Gurus,
I have to open the attached documents in trasaction FB03 but I am recieving the following Error.
ERROR: Error calling application via OLE ALVIEWER.APP.
Thanks and Regards,
Amit.
Hi Amit,
Thanks for the help.
I had one more problem now.
A link is being created in the tcode FB03 when I execute FM ARCHIV_CREATE_TABLE, but when open that link there is no data present inside the document.
If you have an example for the same, It will surely be a great help to me.
Please help.
Regards,
Amit.
Similar Messages
-
Error while Opening PDF attachment from Mail
Hi,
We two Output Types created ZNEU and ZAUF. Two Smartforms are created for the same Output Types. The Issue now is, When ZNEU triggers and send a mail the document is properly decoded and gets opened but for ZAUF it doesn't. It says File damaged.
This is the code we have used for sending mail.
CONSTANTS:
co_pdf(3) TYPE c VALUE 'PDF',
co_raw(3) TYPE c VALUE 'RAW'.
DATA:
it_objbin TYPE STANDARD TABLE OF solisti1,
wa_objbin TYPE solisti1.
DATA:
lv_filesize TYPE i.
DATA:
it_lines TYPE STANDARD TABLE OF tline.
DATA:
wa_mail_body TYPE solisti1,
wa_receipients TYPE somlreci1.
DATA:
document TYPE REF TO cl_document_bcs,
content TYPE solix_tab,
wa_content TYPE solix,
send_request TYPE REF TO cl_bcs,
sender TYPE REF TO if_sender_bcs,
recipient TYPE REF TO if_recipient_bcs,
requested_status TYPE REF TO bcs_rqst,
status_mail TYPE bcs_stml,
bcs_exception TYPE REF TO cx_bcs,
lv_rec TYPE adr6-smtp_addr.
DATA:
wa_attachx TYPE solix,
l_pdf_len TYPE i,
l_con_len TYPE i,
l_pdf_pos TYPE i,
l_con_pos TYPE i.
FIELD-SYMBOLS: <fs_con> TYPE x.
CLASS cl_cam_address_bcs DEFINITION LOAD.
CLASS cl_abap_char_utilities DEFINITION LOAD.
* Get the PDF version of the OTF
CALL FUNCTION 'CONVERT_OTF'
EXPORTING
format = 'PDF'
IMPORTING
bin_filesize = lv_filesize
TABLES
otf = job_output_info-otfdata
lines = it_lines
EXCEPTIONS
err_max_linewidth = 1
err_format = 2
err_conv_not_possible = 3
err_bad_otf = 4
OTHERS = 5.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* Convert the PDF format to the table type required for the attachment.
CALL FUNCTION 'QCE1_CONVERT'
TABLES
t_source_tab = it_lines
t_target_tab = it_objbin
EXCEPTIONS
convert_not_possible = 1
OTHERS = 2.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* Convert the data which is in text to binary
l_con_pos = 0.
DESCRIBE FIELD wa_objbin LENGTH l_pdf_len IN BYTE MODE.
DESCRIBE FIELD wa_attachx LENGTH l_con_len IN BYTE MODE.
LOOP AT it_objbin INTO wa_objbin.
ASSIGN wa_objbin TO <fs_con> CASTING.
CHECK sy-subrc EQ 0.
DO l_pdf_len TIMES.
l_pdf_pos = sy-index - 1.
IF l_con_pos = l_con_len.
APPEND wa_attachx TO content.
FREE wa_attachx.
l_con_pos = 0.
ENDIF.
MOVE <fs_con>+l_pdf_pos(1) TO wa_attachx-line+l_con_pos(1).
ADD 1 TO l_con_pos.
ENDDO.
ENDLOOP.
IF l_con_pos > 0.
APPEND wa_attachx TO content.
ENDIF.
TRY .
* -------- create persistent send request ------------------------
send_request = cl_bcs=>create_persistent( ).
* -------- create and set document with attachment ---------------
* create document from internal table with text
document = cl_document_bcs=>create_document(
i_type = 'RAW'
i_text = mail_body_tab
i_subject = email_subject ).
* add attachment to document
CALL METHOD document->add_attachment
EXPORTING
i_attachment_type = 'PDF'
i_attachment_subject = attachment_name
i_att_content_hex = content.
* add document to send request
CALL METHOD send_request->set_document( document ).
* Set sender
sender = cl_cam_address_bcs=>create_internet_address( sender_id ).
CALL METHOD send_request->set_sender
EXPORTING
i_sender = sender.
* Receipients
LOOP AT receipients_tab INTO wa_receipients .
lv_rec = wa_receipients-receiver.
recipient = cl_cam_address_bcs=>create_internet_address( lv_rec ).
* Add recipient with its respective attributes to send request
CALL METHOD send_request->add_recipient
EXPORTING
i_recipient = recipient.
ENDLOOP.
* Set that you don't need a Return Status E-mail
status_mail = 'N'.
CALL METHOD send_request->set_status_attributes
EXPORTING
i_requested_status = 'N'
i_status_mail = status_mail.
* set send immediately flag
send_request->set_send_immediately( 'X' ).
* Send document
CALL METHOD send_request->send( ).
* COMMIT WORK.
CATCH cx_bcs INTO bcs_exception.
RAISE EXCEPTION bcs_exception.
ENDTRY.
This is in a Class which is been used in the print program for both the Output Types.
Can somebody throw light upon this.
Note: I tried using
but it is not working properly.
Thanks,
Prashanth
Edited by: Prashanth KR on Jan 5, 2010 6:20 AMHi,
Please paste the part of code where you are getting error.
And if you are not clear about where the error is, try searching sdn or google with the error message that you are getting as this issue has been discussed many times earlier.
Check this link.
Error while opening PDF in mail attachment
Hope it helps.
Regards,
Raj -
Error while opening .PDF files in document library sharepoint 2013
Hi
I am getting an error while opening a .pdf file,
Please help me find the solution.
Thanks
ParuLaunch IE -> Click on Gear (settings) -> Manage Add-ons -> Show: All Add-ons ->
There are 2 Adobe Add-ons:
Adobe PDF Reader & Adobe Acrobat Sharepoint Open Document
Double-click both and be sure to click the button "ALLOW ON ALL SITES"
(An * will appear in the field)
http://crowdsupport.telstra.com.au/t5/T-Suite-Applications/There-was-an-error-opening-this-document-The-filename-directory/td-p/197425
http://social.msdn.microsoft.com/Forums/sharepoint/en-US/ae2eea40-9fa6-46be-bca1-ac5eb5597d5e/sharepoint-2010-adobe-reader-error-opening-pdf-files?forum=sharepointgeneralprevious
http://community.office365.com/en-us/f/154/t/46204.aspx?PageIndex=2
disable the Mcafee Firewall Plug In. This is after of course I ran superantispyware to remove some malware. uninstalled and reinstalled the Adobe Reade
https://forums.adobe.com/message/1776202?tstart=0 -
Error while opening PDF attachment sent via mail
Hi,
I am attaching PDF file to PO in me22n and sending the same file as attachment in the mail to the vendor using class CL_BCS.
The mail is sent to the vendor successfully and they are able to successfully open the PDF attachment. But in some cases the mail is successfully received but while opening the attachment it is giving the error as file is corrupted.
Please help me to resolve this issue.
Thanks and regards,
JayashreeHi,
I would like to know what font type, you are using in the forms.
Ideally it should be HELVETICA .
If you are using any other font in your style/form,try changing it to HELVETICA & Test.
Also Check the OTF data at the call of gen. FM,before converting it to PDF.
Regds,
AS
Edited by: abheesawant on Oct 12, 2011 7:48 AM -
Error while Opening an attachment in the process.
Hi All,
I am facing an Issue here, I get an task assigned to me either to approve or reject, but when I try to open the attachment in the request, It tries to opens in the new IE browser, and I get an Error message displyed, as Page cannot open in the new browser.
I also can notice 500 error notice in the browser.
Also,I can able to open attachments of other request comming to my TO Do list, but has a problem with the one mentioned.
Since I am new to workbench server, not sure of the location of Log files and Temp files.
Request you to let me know the reason of this error and need to fix it too.
Kindly answer my questions at the earliest or suggest with any link.
Thanks,
Satish.Possibly the attached might got deleted while in transit. Any information from the server log?
Nith -
Error while openeing PDF attachment sent thru smartform
Hi,
I have tried all the options and also gone thru all the quries and replies in SDN but could not find answer for this.
I have developed a smart from with some table fetch data from PAYR. Now i have written an ABAP code to sent the output of a smartform as PDF in the email.
Im getting an error "There was an error openeing htis doc and file is damaged and coul dnot be repaired".
Here is my code.
CLEAR WA_BUFFER.
LOOP AT I_TLINE.
TRANSLATE I_TLINE USING '~'.
CONCATENATE WA_BUFFER I_TLINE INTO WA_BUFFER.
ENDLOOP.
TRANSLATE WA_BUFFER USING '~'.
CLEAR: I_RECORD. REFRESH: I_RECORD.
DO.
I_RECORD = WA_BUFFER.
APPEND I_RECORD.
SHIFT WA_BUFFER LEFT BY 255 PLACES.
IF WA_BUFFER IS INITIAL.
EXIT.
ENDIF.
ENDDO.
I_OBJBIN] = I_RECORD[.
I_OBJPACK-TRANSF_BIN = 'X'.
I_OBJPACK-HEAD_START = 1.
I_OBJPACK-HEAD_NUM = 1.
I_OBJPACK-BODY_START = 1.
DESCRIBE TABLE I_OBJBIN LINES V_LINES_BIN.
READ TABLE I_OBJBIN INDEX V_LINES_BIN.
I_OBJPACK-DOC_SIZE = V_LINES_BIN * 255 .
I_OBJPACK-DOC_SIZE = ( v_lines_bin - 1 ) * 255 + strlen( i_objbin ).
I_OBJPACK-BODY_NUM = V_LINES_BIN.
I_OBJPACK-DOC_TYPE = 'PDF'.
I_OBJPACK-OBJ_NAME = 'smart'.
I_OBJPACK-OBJ_DESCR = 'test'.
APPEND I_OBJPACK.
I_RECLIST-RECEIVER = 'ABC.gmail.com'.
I_RECLIST-REC_TYPE = 'U'.
APPEND I_RECLIST.
CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
DOCUMENT_DATA = WA_DOC_CHNG
PUT_IN_OUTBOX = 'X'
COMMIT_WORK = 'X'
TABLES
PACKING_LIST = I_OBJPACK
OBJECT_HEADER = WA_OBJHEAD
CONTENTS_BIN = I_OBJBIN
CONTENTS_TXT = I_OBJTXT
RECEIVERS = I_RECLIST
EXCEPTIONS
TOO_MANY_RECEIVERS = 1
DOCUMENT_NOT_SENT = 2
DOCUMENT_TYPE_NOT_EXIST = 3
OPERATION_NO_AUTHORIZATION = 4
PARAMETER_ERROR = 5
X_ERROR = 6
ENQUEUE_ERROR = 7
OTHERS = 8.
IF SY-SUBRC 0.
WRITE:/ 'Error When Sending the File', SY-SUBRC.
ELSE.
WRITE:/ 'Mail sent'.
ENDIF.
Pls help me in sloving out this.
Thanks.Sounds familiar but not sure. Have you tried using OTF format in stead of PDF and in the file name use document.pdf??
-
Error while opening the document
Hi,
i av created the document.while i m trying to oopen the document in tcode :CV02N it s giving me a message as "40.960 bytes transmitted , Code page 0000"
Could me pls tel me what is this message and how to solve this..
Regards
BhanuHi,
Kindly elaborate is this error while opening original attached in DIR or?
If yes!
check in DC20-->whether data carrier is defined
check in DC30-->whether workstation application file is defined propelry or not.
Regards,
Seema Pilankar -
Getting correlation error while opening document library in SharePoint 2010
Hi,
I installed SQL Server 2008 R2 SP1 and SharePoint 2010 on Windows Server 2008 R2. Everything went fine for first days. Now I am getting error while opening any of the document libraries. However lists are opening fine.
Error:
An unexpected error has occured.
Troubleshoot issues with Microsoft SharePoint Foundation
Correlation ID: fa54267f-4436-8298-c7698977728c
I checked the logs, I showing some error with the line http://Microsoft.Office.Server.UserProfiles/GetProfileProperties
Please let me know if you have any idea about this error or let me know if you need further inputs from me. Thanks.Hi Tarique,
Whether you have granted the user proper permissions on this site. You should make sure the user has permissions on the site.
In addition, there are some reasons for the log-in issue, please take a look at:
http://sharepointsolutions.blogspot.com/2008/06/how-do-i-make-our-sharepoint-site-stop.html
http://sharepointsolutions.blogspot.com/2008/06/how-do-i-make-our-sharepoint-site-stop_17.html
http://dinesql.blogspot.com/2011/01/cannot-login-to-sharepoint-2010-site.html
I hope this helps.
Thanks,
Wendy
Wendy Li
TechNet Community Support -
Error while opening office document
Hello Gurus!
I try to use word intergation in WebIC (CRM 5.0). In "Create lead" trunsaction (CL_CRM_IC_ABOXSAMPLE_CR_LEAD class) I have Attachment tab. When I click "Create document with template" buton I get "Error while opening office document" error. In IE settings ActiveX is on. What should I do to make it work?
Best regards,
Artur.Hello Artur,
Try this Note:
Note 606745 - CRM Content Management: Document does not open
It's not exactly for that issue but it may help.
Good Luck
Eli Steklov
Please Reward Points if it Helped -
Hi,
I'm getting the below error for reports.
The report terminated with error:
REP-110: File test2. cannot be opened. REP-1070: An error occurred while opening or saving a document. REP-0110: File test2. cannot be opened. .
When checked Environment using url 'http://host:port/reports/rwservlet/showenv?server=your_repserver_name"
found below
==================================================
Reports Servlet Environment Variables 11.1.1.4.0
Security Mode Non-secure
HTTP Environment Variables 11.1.1.4.0
SERVER_NAME 09.14.4.41
SERVER_PORT 8888
SCRIPT_NAME /rwservlet
SERVER_PROTOCOL HTTP/1.1
SERVER_SOFTWARE undefined
GATEWAY_INTERFACE undefined
SERVER_PORT_SECURE undefined
ACCEPT image/jpeg, application/x-ms-application, image/gif, application/xaml+xml, image/pjpeg, application/x-ms-xbap, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*
REQUEST_METHOD GET
REMOTE_HOST test-wam-app
REMOTE_ADDR 09.14.4.41
REMOTE_USER undefined
AUTH_TYPE undefined
PATH_INFO showenv
QUERY_STRING server=RptSvr_test-wam-app_wamtest
PATH_TRANSLATED undefined
CONTENT_LENGTH undefined
CONTENT_TYPE undefined
AUTHORIZATION undefined
USER-AGENT Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.2; Trident/6.0; .NET4.0E; .NET4.0C; .NET CLR 3.5.30729; .NET CLR 2.0.50727; .NET CLR 3.0.30729; InfoPath.3; MS-RTC LM 8)
REMOTE_IDENT undefined
REFERER undefined
Oracle Reports Services - Servlet Environment Variables Select to jump to the top of the page Return to Top
KeyMapFile /u03/apptest/FMW_11.1.1/user_projects/domains/WamTest/config/fmwconfig/servers/WLS_REPORTS/applications/reports_11.1.1.2.0/configuration/cgicmd.dat
DBAUTH /u03/apptest/FMW_11.1.1/apphome/reports/templates/rwdbauth.htm
SYSAUTH /u03/apptest/FMW_11.1.1/apphome/reports/templates/rwsysauth.htm
server rep_wls_reports_test-wam-app_wamtest1
DIAGNOSTIC yes
ERRORTEMPLATE /u03/apptest/FMW_11.1.1/apphome/reports/templates/rwerror.htm
SERVER_IN_PROCESS yes
COOKIEEXPIRE 30
ENCRYPTIONKEY reports9i
DIAGHEADTAGS undefined
DIAGBODYTAGS undefined
HELPURL undefined
RELOAD_KEYMAP undefined
IMAGEURL http://09.14.4.41:8888/reports/rwservlet
SINGLESIGNON no
Oracle Reports Services - Server and Engine Environment Variables Select to jump to the top of the page Return to Top
PATH /u01/wamtest/FMW_11.1.1/apphome/jdk/bin:/u01/wamtest/FMW_11.1.1/apphome/bin:/u01/wamtest/FMW_11.1.1/apphome/jdk/bin:/u01/wamtest/FMW_11.1.1/apphome/bin:/u01/wamtest/FMW_11.1.1/apphome/bin:/u01/wamtest/FMW_11.1.1/apphome/bin:/u01/java/jdk1.6.0_23/bin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin
DISPLAY
LD_LIBRARY_PATH /u01/wamtest/FMW_11.1.1/apphome/jdk/jre/lib/amd64/server:/u01/wamtest/FMW_11.1.1/apphome/jdk/jre/lib/amd64:/u01/wamtest/FMW_11.1.1/apphome/jdk/jre/../lib/amd64:/u01/wamtest/FMW_11.1.1/apphome/jdk/jre/lib/amd64/native_threads:/u01/wamtest/FMW_11.1.1/apphome/jdk/jre/lib/amd64:/u01/wamtest/FMW_11.1.1/apphome/lib:/u01/wamtest/FMW_11.1.1/apphome/jdk/jre/lib/amd64/server:/u01/wamtest/FMW_11.1.1/apphome/jdk/jre/lib/amd64/native_threads:/u01/wamtest/FMW_11.1.1/apphome/jdk/jre/lib/amd64:/u01/wamtest/FMW_11.1.1/apphome/lib:/u01/wamtest/FMW_11.1.1/apphome/jdk/jre/lib/amd64/server:/u01/wamtest/FMW_11.1.1/apphome/opmn/lib:/u01/wamtest/FMW_11.1.1/apphome/lib
ORACLE_HOME /u01/wamtest/FMW_11.1.1/apphome
TNS_ADMIN /u01/wamtest/FMW_11.1.1/instance1/config
NLS_LANG AMERICAN_AMERICA.WE8ISO8859P1
USER_NLS_LANG
RW /u01/wamtest/FMW_11.1.1/apphome/reports
REPORTS_PATH /u01/wamtest/FMW_11.1.1/apphome/reports/templates:/u01/wamtest/FMW_11.1.1/apphome/reports/samples/demo:/u01/wamtest/FMW_11.1.1/apphome/reports/integ:/u01/wamtest/FMW_11.1.1/apphome/reports/printers:/u01/wamtest/FMW_11.1.1/instance1/reports/fonts:/u01/wamtest/FMW_11.1.1/apphome/reports/templates:/u01/wamtest/FMW_11.1.1/apphome/reports/samples/demo:/u01/wamtest/FMW_11.1.1/apphome/reports/integ:/u01/wamtest/FMW_11.1.1/apphome/reports/printers:/u01/wamtest/FMW_11.1.1/instance1/reports/fonts:
REPORTS_TMP /tmp
REPORTS_TAGLIB_URI /WEB-INF/lib/reports_tld.jar
java.class.path /u01/wamtest/FMW_11.1.1/apphome/reports/jlib/rwrun.jar
sourceDir
tempDir
useDataCache
ignoreDataParameter
=========================================================================
ORACLE_HOME is on mount point u03, checked config.properties but no mention of mount point /u01.
Dont know from where /u01 came. Could you please help me re configuring the env pointing to /u03.
Reports server is up though without any issues.
Regards,
DjayEnsure that the report name is correct. Also ensure that the report exist in REPORTS_PATH environment variable. Otherwise run the report including the reports path.
E.g.
report=<reports directory>/test2.rdf -
Getting error while opening Excel document from SharePoint site
Hello All,
I am getting following error while opening Excel document from SharePoint site.
This issue appears when we open Excel document from Windows>> Run using below mentioned command:
Excel.exe "{File Name}"
If once I go to Excel back stage and browse for the SharePoint location, then this problem disappears.
I have a work around for this issue but main problem is that i do not have any work around when i need to open Exel document using Excel COM interop in C#.
Thanks,
Amit Bansal
Amit Bansal http://www.oops4you.blogspot.com/Hi Amit Bansal,
Thanks for posting in MSDN forum.
This forum is for developers discussing developing issues involve Excel application.
According to the description, you got an error when you open the document form SharePoint site.
Based on my understanding, this issue maybe relative to the SharePoint, I would like move it to
SharePoint 2013 - General Discussions and Questions forum.
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.
Thanks for your understanding.
Regards & Fei
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey. -
Getting error while opening document in SharePoint 2010
Hi,
I got the below error while opening a document in SharePoint library.
"The document could not be opened for editing. A Microsoft SharePoint Foundation compatible application could not be found to edit the document."
Please help me to resolve.
KrishnasandeepHi,
According to your post, my understanding is that you got the error while opening a document in SharePoint library.
The issue can occur when you have several different versions of Office installed on the same computer and you have
several different versions of the OWSSUPP DLL available which are not registered correctly.
To resolve this issue you should disable Microsoft SharePoint Foundation Support in any other version of Office installed on the machine and then repair Office.
For more information: you can refer to:
You get an error message when you open an Office file from SharePoint on a computer on which you installed more than one version of Office
In addition, please ensure that you are using Internet Explorer (32 bit) not the Internet Explorer (64-bit).
Please Verify the “Sharepoint OpenDocuments Class” addon is installed and enabled. If it is not reinstall Office.
Please refer to:
Solved: The document could not be opened for editing. A Microsoft SharePoint Foundation compatible application could not be found to edit the document.
And, if the Office tools can’t install correctly will also cause the error.
Here is a thread about this issue, you can check it. The replies include most of the possible reasons and gave the solutions.
http://social.msdn.microsoft.com/Forums/en-US/06a4943a-5150-44c5-ae6b-3354c85396f5/the-document-could-not-be-opened-for-editing-a-microsoft-sharepoint-foundation-compatible
Best Regards,
Linda Li
Linda Li
TechNet Community Support -
Error Message "Error while Opening the Document"
Hi Friends,
I have a problem while opening the SFP transaction and Clicking on the Layout Tab the SAP System is giving an error message saying "Error while Opening the Document".
I have tried testing on several systems like IDES, ERP, Retail systems. But it is giving me same error. Is this the problem with ADOBE LIVECYCLE DESIGNER?
And when I click on the Performance Assistant it has given me some information:
Error while opening document
Message no. SOFFICEINTEGRATION143
Diagnosis
An error occurred in the desktop application while opening a document.
Friends can you help me in solving this problem.
Thanking yoy in Advance
Pradeep GoliPradeep,
Maybe Live Cycle Designer has not been uninstalled correctly from your system. So goto the following lcaotions and remove the Designer folder if you find them:-
C:\Program Files\Adobe
C:\Documents and Settings\<your-username>\Application Data\Adobe\
Alternatively try installing Live Cycle Designer on some other machine in your network and see if you encounter the same error.
Similar thread for reference : Error - Adobe Live Cycle designer
Chintan -
Experts:
I am working on sending Excel as an email attachment thro the function module 'SO_NEW_DOCUMENT_ATT_SEND_API1'
I am able to send mail successfully but I face the following two issues while opening the attachment.
1. While opening it says 'un recognized format' , on pressing 'OK' it opens the excel file.
2. The column heading (first row) which should be in Korean character is displayed in junk char. I tried to
specify the unicode (Code Page = '8500') but does not know how to do it.
I am reading the column header text from standard text.
Please let me know what mistake I have commited in my code and where I should specify the unicode transformation. I refered many samples but could not make it.
Please let me know the error.
The code is as follows.
FORM sendemail_barcodedata.
TYPE-POOLS: truxs.
DATA: objpack LIKE sopcklsti1 OCCURS 2 WITH HEADER LINE.
DATA: objhead LIKE solisti1 OCCURS 1 WITH HEADER LINE.
DATA: objbin LIKE solisti1 OCCURS 10 WITH HEADER LINE.
DATA: objbin1 LIKE solisti1 OCCURS 10 WITH HEADER LINE.
DATA: objtxt LIKE solisti1 OCCURS 10 WITH HEADER LINE.
DATA: reclist LIKE somlreci1 OCCURS 5 WITH HEADER LINE.
DATA: doc_chng LIKE sodocchgi1.
DATA: tab_lines LIKE sy-tabix.
DATA: l_sent_to_all TYPE sonv-flag.
* Creating the document to be sent
* File Name
doc_chng-obj_name = 'BCODEINFO'.
* Mail Subject
doc_chng-obj_descr = 'Delivery Barcode Information'.
* Mail Content
objtxt = 'Hi:'.
APPEND objtxt.
objtxt = 'Find attached, Delivery Barcode Information'.
APPEND objtxt.
CONCATENATE 'Attachment : <<' w_fname1 '>>' INTO objtxt.
APPEND objtxt.
DESCRIBE TABLE objtxt LINES tab_lines.
READ TABLE objtxt INDEX tab_lines.
doc_chng-doc_size = ( tab_lines - 1 ) * 255 + STRLEN( objtxt ).
doc_chng-obj_langu = sy-langu.
doc_chng-sensitivty = 'F'.
* Creating the entry for the compressed document
CLEAR objpack-transf_bin.
objpack-head_start = 1.
objpack-head_num = 0.
objpack-body_start = 1.
objpack-body_num = tab_lines.
objpack-doc_type = 'RAW'.
APPEND objpack.
* Creating the document attachment
* Get column names for Barcode Data
CLEAR objbin.
CONCATENATE text-h23
text-h24
text-h25
text-h26
text-h27
INTO objbin SEPARATED BY con_tab .
CONCATENATE objbin con_cret INTO objbin.
APPEND objbin.
CLEAR objbin.
LOOP AT it_excel2 INTO wa_excel2.
CONCATENATE wa_excel2-zz_date
wa_excel2-zz_delivery
wa_excel2-zz_barcode
wa_excel2-blank1
wa_excel2-blank2
INTO objbin SEPARATED BY con_tab.
CONCATENATE objbin con_cret INTO objbin.
APPEND objbin.
CLEAR objbin.
ENDLOOP.
DESCRIBE TABLE objbin LINES tab_lines.
objhead = w_fname1.
APPEND objhead.
* Creating the entry for the compressed attachment
objpack-transf_bin = 'X'.
objpack-head_start = 1.
objpack-head_num = 1.
objpack-body_start = 1.
objpack-body_num = tab_lines.
objpack-doc_type = 'XLS'.
objpack-obj_name = 'Barcode Information'.
objpack-obj_descr = 'Barcode Information'.
objpack-doc_size = tab_lines * 255.
APPEND objpack.
* Entering names in the distribution list
reclist-receiver = p_email.
reclist-rec_type = 'U'.
APPEND reclist.
* Sending the document
CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
document_data = doc_chng
put_in_outbox = ' '
commit_work = 'X'
IMPORTING
sent_to_all = l_sent_to_all
TABLES
packing_list = objpack
object_header = objhead
contents_bin = objbin
contents_txt = objtxt
receivers = reclist
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
document_type_not_exist = 3
operation_no_authorization = 4
parameter_error = 5
x_error = 6
enqueue_error = 7
OTHERS = 8.
CASE sy-subrc.
WHEN 0.
MESSAGE i000(z65f_msgclass) WITH text-211.
WHEN 1.
WRITE: / 'no authorization to send to the specified number of'.
WHEN 2.
WRITE: / 'document could not be sent to any of the recipients!'.
WHEN 4.
WRITE: / 'no authorization to send !'.
WHEN OTHERS.
WRITE: / 'error occurred during sending !'.
ENDCASE.
ENDFORM.
Thanks in advance.
Regards
VijaiHi:
Can any one provide me a solution for this?
regards
vijai -
APEX 4.0: error while opening a XLS file downloaded from interactive report
Hi,
I'm getting below error while opening a XLS file downloaded from an interactive report (APEX 4.0).
"The file you trying to open, 'customer_2.xls', is in a different format than specified by the file extension.
Verify that the is not corrupted and is from a trusted source before opening file. Do you want to open file."
Yes No Help
May be this one Apex 4.0 issue.
please help me.
Thanks
MukeshHi,
is the next part of the code correct.
What i mean is packing of the attachment, finding out the size of pdf file and doc type as PDF.
You can also try below link..
Link: [http://wiki.sdn.sap.com/wiki/display/Snippets/SENDALVGRIDASPDFATTACHMENTTOSAPINBOXUSINGCLASSES]
Hope this helps.
Regards,
-Sandeep
Maybe you are looking for
-
Pages 5 Where is text box linking and autoflow?
Pages 5 appears to be missing the ability to link text boxes and autoflow them. This is really important for the imposition (putting the printed pages in order) of small booklets. Does anyone know if it is possible in Pages 5?
-
HT2497 Connected to wifi but can't get on internet on MacBook Pro laptop
Connected to wifi but can't use internet on laptop??
-
Downgrade to older itunes version that came w/ipod
i recently downloaded the new ipod update(why did i do that?) and the new itunes upgrade. after all the mess that the ipod update did, i decided to try to restore the ipod and go back to the older stuff that worked. when i installed the old ipod upda
-
Classic won't start, can't upgrade, and other problems...
There's something not quite right with my Mac, and I can't quite pinpoint it. Because of this, I'm not even certain I'm posting this in the right forum! Here's the situation: I have a PowerMac G4, upgraded with a an extra hard drive, an ATI Radeon Pr
-
Oracle Web Cache Administration and Deployment Guide
Does anyone know where the Oracle Web Cache Administration and Deployment Guide is? From Oracle9iAS Documentation Library CD-ROM, it says this document is in OTN. However, I just can't find this document in OTN. Any idea?