Conversion from .prn file into .pdf file

How to convert printer file (.prn) into PDF using ghostscript in C#.Net programmatically?

Hi ammulu135,
This forum is specific to discuss problems of C# development. For Ghostscript product is not from Microsoft. I am
afraid this issue is out of our support. Thanks for your understanding.
Have a nice day!
Kristin
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.

Similar Messages

  • Audio Recording - Conversion from .caf files to mp3 / flv

    Hi,
    Does anybody has done any dynamic audio conversion from .caf files to mp3 or flv format? Basically we have an Iphone app that is recording audio and it saves the data in a SQL Server Database but we want to share this audio in a website. The website need to be able to play the audio in Flash. Does this make sense? I've seen some libraries out there but the Services and Environment are running on Windows so the conversion may be need to be on that environment.
    Thanks,

    The .cda files you see on the CD are a red herring. Bet you any money you're using Windows. :-)
    Besides that, this question has absolutely nothing to do with Collections.

  • Converting the layout from OTF format into PDF

    Hi Experts,
    I am new to SMART FORMS,I don't have a clue about how to convert the layout from OTF format into PDF format and how to store it in Presentation server.
    Please send me a Model program or step by step approach of the same.
    Useful inputs will be rewarded higher points.
    Thanks in Advance,
    Dharani

    Hi,
    The steps are given below:-
    1) First get the name of your generated function module for the smartforms.
    2) Then call the generated function module.
    3) Then use the FM:CONVERT_OTF' to convert into PDF as shown below:-
    call function 'CONVERT_OTF'
        EXPORTING
          format                = 'PDF'
        IMPORTING
          bin_filesize          = w_pdf_len
          bin_file              = w_pdf_xstring
        TABLES
          OTF                   = OUTPUT_DATA-OTFDATA
          LINES                = LT_LINES
        EXCEPTIONS
          err_max_linewidth     = 1
          err_format            = 2
          err_conv_not_possible = 3
          err_bad_otf           = 4
          others                = 5.
    Hope this is clear.
    Pravat.
    <i>*Reward points if helpful.</i>

  • Automatic conversion from XDP file fo PDF file

    Hello!
    I have an application that creates an XDP file with a certain report.
    I can open the XDP file in Designer 7.0 and then save it as PDF, but I would like to know, how can I automatically produce PDF file from XDP file.
    Is it possible?
    Thanks for your answers,
    Bostjan

    Hi All:
    We have a similar requirement for our product.
    We have existing XDP templates (for use with Form server), but we have a need for another Client using an older version of XML Forms - AcroForms (PDF Forms).
    So, we need to convert these XML forms in XDP files into PDF Forms (AcroForms). We tried File->SaveAs (PDF Forms) from Adobe designer, but it looks like the hidden fields (in XDP files) get messed-up.
    Did you guys find any solution for this? I would appreciate if you can share your experiences and insights in this regard.
    Thanks
    Shashi Velur

  • How do you keep embedded documents during conversion from Word 2007 to PDF?

    Windows 7, with all available patches.
    Word 2007, with all available patches.
    Acrobat reader 9.3.2
    I have additional documents, spreadsheets etc embedded into a Microsoft Office Word document. When this document is converted to the PDF (using the Word PDF add-in interface) the embedded objects can no longer be opened and only appear as images. 
    Is there a way to retain the embedded document during the conversion so that they can be opened from within the resulting PDF?
    Thanks in advance!

    Thanks very much for your repsonse, it's much appreciated
    I don't have Acrobat X installed at this time so am not able to create or edit PDFs (other than from Word).  I understand that creating a PDF from Word may not be an Acobat issue per se, but thought that someone on this forum may have experienced a similar problem, hence thought I'd try my luck here
    I will do as you suggest and try an MS forum
    Thanks again

  • Conversion from Word 2007 to PDF/X

    Is there a monthly subscription service to Acrobat XI PRO so that I could convert a Word document with
    text, graphs, and photos into PDF/X-1a or PDF/X-3?  None of the subscription services that I saw expressly
    state the type of conversion except to say its to PDF.  Why is this so hard for sales and Customer Service
    to figure this out?

    You can subscribe to Acrobat XI Pro via Creative Cloud, or as a standalone application.
    http://www.adobe.com/products/creativecloud.html
    http://www.adobe.com/products/acrobatpro/buying-guide.html

  • File conversion, from .mpg files to useable files for iMovie on new MacBook

    i wasnt really sure where to post this, but since my end goal is to be able to use all my videos for editing on iMovie it seemed like the best place, i have many .mpg files that i would like to simply convert to a file of equal quality that iMovie will recognize, theres pages and pages of converters on google but they either are trial versions that will leave water marks or there are websites that will only convert files up to 100mb, i just need a simple converter for the videos i have, i dont want to spend 50 bucks on software that ill only use once and i obviously dont want water marks or a decrease in quality, if anyone has any suggestions that would be great.

    You want MPEG Streamclip: http://www.squared5.com/svideo/mpeg-streamclip-mac.html which is a free download.
    If your movie is an MPEG-2 or VOB file (i.e. from an unencrypted DVD), you also need the MPEG2 Playback Component from Apple: http://www.apple.com/quicktime/mpeg2/ which costs US$19.99

  • Import bookmarks from word 2003 into PDF

    Hello guys,
    my english is not the best but i will try my best :-)
    My enviroment:
    Microsoft Windows Server 2008 R2 SP1 with XenApp 6, Office 2003 SP3 and Adobe Acrobat 9.
    My problem:
    I installed Adobe Acrobat 9 without Adobe Tabs / PlugIns for Office.
    One user write a document in Word 2003 with many bookmarks. He try to convert the document into a PDF. But after converting the bookmarks are not included in the PDF.
    He try to convert the document over the PDF printer and in Acrobat over create -> pfd from file. Both ways are not working.
    So now my question: Is there any way to convert a doc into a PDF without using the Adobe Tabs / PlugIn for Office?
    Thanks a lot.

    - Open Word 2003, you should see a "Adobe PDF" or "Acrobat" menu item.
    - Select the option to change preferences
    - Select the Bookmarks tab
    - Select the option to convert Word Bookmarks

  • How Automate Dynamically Embedding Customer Names from a List into PDF Footer?

    Mavens,
    After discovering that a PDF training workbook of mine has been widely copied (without authorization), I'd like to "personalize" future versions of this artifact with the customer/user name dynamically embedded in each PDF's footer.
    Based on your experience, what is the easiest, quickest & most economical way to: generate a set of PDFs (from a "Master") where each individual PDF is personalized with a user/customer name in the footer (e.g., "This document is licensed to {FRED BLOTZ} at {BIG COMPANY, Inc.}. Duplication or distribution is not authorized.").
    The desired workflow is:
    1. Create an MS-Excel Workbook with a list of all trainee (user) names.
    2. Open some type of "PDF Personalization" tool.
    3. Provide the path to the "Master PDF" to the tool.
    4. Provide the name of the customer (company) to the tool.
    5. Provide a path to the MS-Excel Workbook with list of individual's names.
    6. Provide a path to a folder where the tool should write the generated PDFs.
    7. Click a button ("Generate Personalized PDFs").
    Then...distribute individualized PDFs to trainees.
    Is there a tool out there somewhere which provides the desired solution?
    Thank you in advance for your experienced-based suggestions.
    Plane Wryter
    PS: While I fully appreciate the on-going discussions regarding the merits/lack-of-merits of DRM, etc...if you elect to reply to this request...please be so kind as to focus on the question as presented and avoid clambering onto a soapbox to "rant" about DRM...or suggest increasing the fee to the customer (a big firm that only pays "per-trainee" fees) to cover distribution. Thank you.

    go to database, show sql query. please paste the query in here it will be easier to help you
    if you cant seem to get it from there, go to database, database expert and edit the command file. (if that is the dataset you are using) copy and paste that.

  • Problem with conversion of Vc output into PDF format

    hi all,
    In r/3 i created a RFC to get a company detail list.
    I am calling this RFC into iview.
    outputs of the iview are a char info field called 'REPTNAME' and a table which displays the list.
    i have created a button called 'PDF' on a table .
    for this button i have written a code like
    "pcd!portal_content!com.sap.gm.cnt!platform-add_ons!com.sap.ip.bi!iview u1!?QUERY="&STORE@REPTNAME&"&BI_COMMAND_1-EXPORT_FORMAT=PDF&BI_COMMAND_1-SHOW_EXPORT_DIALOG=X&BI_COMMAND_1-null="
    but when i am clicking this button , its takin me to another window of  cluster administration.
    i am not getting why this is happening.
    and i also don have idea about BI statements. i copied this code( For button) from existing Documents on VC provided on the site

    hi,
    yes i have gone only through this link..
    i tried every way..
    i have created a button using edit toolbar for table control.
    Using system action, and in hyperlink i have put the below formula in 'formula' window.
    i have come across a point i would like to discuss.
    and that is,
    If i enter
    "pcd!portal_content!com.sap.gm.cnt!platform-add_ons!com.sap.ip.bi!iview u1!?QUERY="&STORE@REPTNAME&"&BI_COMMAND_1-EXPORT_FORMAT=PDF&BI_COMMAND_1-SHOW_EXPORT_DIALOG=X&BI_COMMAND_1-null="
    this in formula for the button,
    after clicking the button it takes me to the cluster administration window
    and if i enter
    "pcd!portal_content!com.sap.gm.cnt!platform-add_ons!com.sap.ip.bi!iviews!com.sap.ip.bi.bexwebanalyzer?QUERY="&STORE@REPTNAME&"&BI_COMMAND_1-EXPORT_FORMAT=PDF&BI_COMMAND_1-SHOW_EXPORT_DIALOG=X&BI_COMMAND_1-null="
    it takes me to the exception error.
    if you observe these two ,there is a difference of
    ' com.sap.ip.bi.bexwebanalyzer '  this statement.
    so can you pls tell me wat this will be??

  • How to automate the generation of several Word documents into PDF?

    I want to generate in batch processes the conversion from Word documents into PDF. Could you tell me how?
    Thank yoou.

    Thank you for your answers.
    But I would like to launch a batch to generate PDFs and I don't find any explanation in the Adobe documentation telling how to do.
    Do you have any idea?

  • Create pdf-files trough prn-files in a windows service applicatio

    Hi,
    i have also the problem to create pdf-files from .prn-files.
    in normall windows aplication we ar using the distiller but we would like to create the pdf's by running our application as windows service.
    in this case it is not possible to use the distiller. As i understood we have to use the acrobat PDG Generator as a server application.
    My question is, is it possible to make function calls to the service where i pass trough the prn-file and the according pdf-file is than created immediately.
    This is important because the created pdf-file ist than used for different purposes.

    Hi psprenge,
    As per your request of refund,
    I have cancelled your subscription, and set the refund process in motion.
    Your refund no.is 66193634.
    Regards,
    Florence

  • ITunes will no longer play nor add to the library any mp3 files which I have created by conversion from a wav file.

    I am running iTunes 10 on XP Pro and it will no longer play those mp3 files which I have created by conversion from wav files.  I tried to delete some from the library and then re-add them but iTunes will not add them back to the library.
    Can anyone help solve this, please?

    Back up your purchased music before you upgrade, I've read at least 5 cases where purchased music has just gone.....missing.
    That is not supposed to happen, didn't happen to me or thousnds of other iTunes users, but you don't want to be the 6th person, do you?
    There are two things to try before you upgrade:
    Barbara Hall, "Unknown Error (-208)" #1, 07:42pm Oct 19, 2005 CDT
    http://docs.info.apple.com/article.html?artnum=302478

  • FFT of waveform (lvm file converted from mat file) - how do I overcome dt error =0?

    Hi,
    I am using an lvm file after conversion from mat file. I wanted to get the fft  spectrum.I keep getting this error that waveform dt<=0.
    How do I overcome it?
    I have attached the mat file and the vi i used.
    Best regards,
    Fesmi
    Solved!
    Go to Solution.

    The Forum is somewhat particular about the files which may be attached. Often creating a zip file works. Sometimes you can change the extension to .txt. If you change the extension, please indicate in your post what the orignal extension was.
    It appears that the data in the file has a time column and an amplitude column. The LabVIEW waveform datatype is a cluster of an array of amplitudes (Y), sampling interval (dt), starting time (t0), and optional attributes. This is what the Power Spectrum VI requires as an input. The t0 values is not used so the defualt is fine. the dt value can be calculated from the difference of any two adjacent values in the time column. Since the first value is zero, the second value is equal to dt.  Use the Build Waveform primitive from the Waveform palette.  Expand it to show the dt element.
    In the attached VI all rows is an indicator which contains the data from your file saved as default. XY Graph plots that data.  After subtracting the mean to get rid of a DC component, the data is converted to a waveform. The power spectrum is calculated and displayed using the same VI as in your program. It also uses Extract Multiple Tone Information.vi to get the frequency and amplitude of the major peaks in the data.
    Interestingly the low frequency part of the spectrum has strong harmonics of 60 Hz while the peaks near 4 kHz are space ~100 Hz apart.  The broad peak near 2.1 kHz does not seem to have noticeable components at either 60 or 100 Hz.
    How do you avoid the Dynamic Data Type (DDT)? Stop using Express VIs! For reasons only known to NI, Express VIs deliver their outputs via DDT. Except by opening the block diagram of the express VI, there is no way to tell what the underlying data structure on a DDT wire is. 
    Lynn
    Attachments:
    FFT of Waveforms.vi ‏711 KB

  • Smart form   out put  into PDF ????

    How to download into PDF file  after the execute Smart form out put ????

    hi,
    pls try this code.
    *& Report : ZPDF_FORMAT
    *& Description : Conversion of Purchase Order into PDF format
    *& used in the workflow (Do Not Change or Delete).
    REPORT zpdf .
    *& Tables used
    TABLES: nast, tsp01, t024, spop, lfa1, tnapr.
    *& Data declaration
    DATA: spoolno LIKE tsp01-rqident.
    DATA: rcode LIKE sy-subrc.
    *data: doc_auth like zoutput-ztag.
    DATA: cancel.
    DATA: pdf LIKE tline OCCURS 0 WITH HEADER LINE.
    DATA: numbytes TYPE i,
    pdfspoolid LIKE tsp01-rqident,
    jobname LIKE tbtcjob-jobname,
    jobcount LIKE tbtcjob-jobcount,
    is_otf.
    DATA: client LIKE tst01-dclient,
    name LIKE tst01-dname,
    objtype LIKE rststype-type,
    type LIKE rststype-type.
    DATA: dir_loc(3).
    DATA: t_docno LIKE vbak-vbeln..
    DATA: spoolreq1 LIKE tsp01sys.
    DATA: spoolreq LIKE rsporq OCCURS 0 WITH HEADER LINE.
    DATA: t_frgke LIKE ekko-frgke.
    DATA: okcode(10),
    flag,
    t_ekgrp LIKE ekko-ekgrp,
    t_lifnr LIKE ekko-lifnr,
    s_mail.
    Data Declartion for mailing system - Start.
    DATA: objpack LIKE sopcklsti1 OCCURS 0 WITH HEADER LINE.
    DATA: objhead LIKE solisti1 OCCURS 0 WITH HEADER LINE.
    DATA: objbin LIKE solisti1 OCCURS 0 WITH HEADER LINE.
    DATA: objtxt LIKE solisti1 OCCURS 0 WITH HEADER LINE.
    DATA: reclist1 LIKE somlreci1 OCCURS 500 WITH HEADER LINE.
    DATA: reclist LIKE somlreci1 OCCURS 500 WITH HEADER LINE.
    DATA: itab LIKE somlreci1 OCCURS 50 WITH HEADER LINE."RKU 220802
    DATA: doc_chng LIKE sodocchgi1.
    DATA: BEGIN OF bdcdata OCCURS 0.
    INCLUDE STRUCTURE bdcdata.
    DATA: END OF bdcdata.
    DATA: tab_lines LIKE sy-tabix.
    DATA: verkf LIKE ekko-verkf.
    DATA: bemail(250), vemail(250).
    Data acceptance
    SELECTION-SCREEN BEGIN OF BLOCK blk0_input WITH FRAME .
    PARAMETERS: docno LIKE ekko-ebeln OBLIGATORY LOWER CASE.
    SELECTION-SCREEN SKIP.
    SELECTION-SCREEN END OF BLOCK blk0_input.
    Initialisation
    *initialization.
    Screen Parameters Validation
    *at selection-screen.
    AT SELECTION-SCREEN.
    SELECT SINGLE frgke INTO t_frgke FROM ekko
    WHERE ebeln = docno
    AND frgke = 'R'.
    IF sy-subrc <> 0.
    MESSAGE 'DOCUMENT NOT RELEASED' TYPE 'E'.
    ENDIF.
    Execution Part
    START-OF-SELECTION.
    For PO related operation
    Dislay Buyer Group, Name and Email id
    SELECT SINGLE
    ekgrp
    lifnr
    verkf
    INTO (t_ekgrp, t_lifnr, verkf)
    FROM ekko
    WHERE ekko~mandt = sy-mandt
    AND ebeln = docno.
    IF sy-subrc = 0.
    SELECT SINGLE * FROM lfa1
    WHERE lfa1~mandt = sy-mandt
    AND lifnr = t_lifnr.
    ENDIF.
    Get message status from NAST or assign msg status NAST stru
    Pass the message status and get spool data
    PERFORM check_output_create_spool.
    IF rcode NE 0.
    IF rcode = 9.
    message s185 with text-e04.
    ELSE.
    message s185 with text-e01.
    ENDIF.
    EXIT.
    ENDIF.
    find the spool
    PERFORM find_spool_request_id.
    IF sy-subrc <> 0.
    message s185 with text-003.
    EXIT.
    ENDIF.
    READ TABLE spoolreq
    WITH KEY rq0name = nast-dsnam
    rq1name = 'LP01'
    rqclient = '800'
    rq2name = sy-uname
    rqowner = sy-uname.
    IF sy-subrc <> 0.
    CASE sy-subrc.
    WHEN 1.
    message s185 with text-e03.
    WHEN OTHERS.
    message s185 with text-e02.
    ENDCASE.
    EXIT.
    ENDIF.
    spoolno = spoolreq-rqident.
    Convert SPOOL job to PDF
    PERFORM convert_spool_to_pdf.
    Send through mail
    PERFORM assign_data_4_mail.
    PERFORM send_mail_with_attachment.
    Delete created spool request
    spoolreq1-rqident = spoolno.
    PERFORM delete_spool_job.
    *& Form check_output_create_spool
    text
    --> p1 text
    <-- p2 text
    FORM check_output_create_spool.
    SELECT SINGLE * FROM nast WHERE objky = docno
    AND kappl = 'EF'
    AND kschl = 'NEU'
    AND aktiv = space
    AND nacha = '1'.
    IF sy-subrc EQ 0.
    COUNT = COUNT + 1.
    PERFORM mssage_status_field_value.
    nast-vsztp = '4'.
    PERFORM einzelnachricht_dialog(rsnast00) USING rcode.
    ELSE.
    CLEAR nast-uhrvr.
    CLEAR nast-cmfpnr.
    CLEAR nast-datvr.
    PERFORM mssage_status_field_value.
    nast-vsztp = '4'.
    PERFORM einzelnachricht_dialog(rsnast00) USING rcode.
    else.
    rcode = 9.
    ENDIF.
    ENDFORM. " check_output_create_spool
    *& Form mssage_status_field_value
    text
    --> p1 text
    <-- p2 text
    FORM mssage_status_field_value .
    nast-mandt = '800'.
    nast-kappl = 'EF'.
    nast-kschl = 'NEU'.
    nast-objky = docno.
    nast-ldest = 'LP01'.
    nast-anzal = 1.
    nast-dimme = 'X'.
    nast-delet = 'X'.
    nast-nacha = '1'.
    nast-vsztp = '2'.
    nast-spras = 'E'.
    nast-vstat = '0'.
    nast-manue = 'X'.
    nast-erdat = sy-datum.
    nast-eruhr = sy-uzeit.
    nast-usnam = sy-uname.
    nast-tdreceiver = sy-uname.
    concatenate sy-uzeit+2(4) 'PDF' into nast-dsnam.
    ENDFORM. " mssage_status_field_value
    *& Form find_spool_request_id
    text
    --> p1 text
    <-- p2 text
    FORM find_spool_request_id.
    CALL FUNCTION 'RSPO_FIND_SPOOL_REQUESTS'
    EXPORTING
    allclients = '800'
    authority = ' '
    datatype = '*'
    has_output_requests = '*'
    rq0name = nast-dsnam "'*'
    rq1name = '*'
    rq2name = '*'
    rqdest = 'LP01'
    rqident = 0
    rqowner = sy-uname
    TABLES
    spoolrequests = spoolreq
    EXCEPTIONS
    no_permission = 1
    OTHERS = 2.
    ENDFORM. " find_spool_request_id
    *& Form convert_spool_to_pdf
    text
    --> p1 text
    <-- p2 text
    FORM convert_spool_to_pdf.
    SELECT SINGLE * FROM tsp01 WHERE rqident = spoolno.
    IF sy-subrc <> 0.
    WRITE: / 'Spool order does not exist'
    COLOR COL_NEGATIVE.
    EXIT.
    ENDIF.
    client = tsp01-rqclient.
    name = tsp01-rqo1name.
    CALL FUNCTION 'RSTS_GET_ATTRIBUTES'
    EXPORTING
    authority = 'SP01'
    client = client
    name = name
    part = 1
    IMPORTING
    type = type
    objtype = objtype
    EXCEPTIONS
    fb_error = 1
    fb_rsts_other = 2
    no_object = 3
    no_permission = 4.
    IF objtype(3) = 'OTF'.
    is_otf = 'X'.
    ELSE.
    is_otf = space.
    ENDIF.
    IF is_otf = 'X'.
    CALL FUNCTION 'CONVERT_OTFSPOOLJOB_2_PDF'
    EXPORTING
    src_spoolid = spoolno
    no_dialog = ' '
    IMPORTING
    pdf_bytecount = numbytes
    pdf_spoolid = pdfspoolid
    btc_jobname = jobname
    btc_jobcount = jobcount
    TABLES
    pdf = pdf
    EXCEPTIONS
    err_no_otf_spooljob = 1
    err_no_spooljob = 2
    err_no_permission = 3
    err_conv_not_possible = 4
    err_bad_dstdevice = 5
    user_cancelled = 6
    err_spoolerror = 7
    err_temseerror = 8
    err_btcjob_open_failed = 9
    err_btcjob_submit_failed = 10
    err_btcjob_close_failed = 11.
    if sy-subrc <> 0.
    case sy-subrc.
    when 1.
    write: / text-001 color col_positive.
    when 2.
    write: / text-002 color col_negative.
    exit.
    when 3.
    write: / text-003 color col_negative.
    exit.
    when 4.
    write: / text-004 color col_negative.
    exit.
    when others.
    write: / text-005 color col_negative.
    exit.
    endcase.
    endif.
    ELSE.
    CALL FUNCTION 'CONVERT_ABAPSPOOLJOB_2_PDF'
    EXPORTING
    src_spoolid = spoolno
    no_dialog = ' '
    DST_DEVICE =
    PDF_DESTINATION =
    IMPORTING
    pdf_bytecount = numbytes
    pdf_spoolid = pdfspoolid
    LIST_PAGECOUNT =
    btc_jobname = jobname
    btc_jobcount = jobcount
    TABLES
    pdf = pdf
    EXCEPTIONS
    err_no_abap_spooljob = 1
    err_no_spooljob = 2
    err_no_permission = 3
    err_conv_not_possible = 4
    err_bad_destdevice = 5
    user_cancelled = 6
    err_spoolerror = 7
    err_temseerror = 8
    err_btcjob_open_failed = 9
    err_btcjob_submit_failed = 10
    err_btcjob_close_failed = 11.
    case sy-subrc.
    when 0.
    *write: / 'Funktion CONVERT_ABAPSPOOLJOB_2_PDF erfolgreich
    *(successful)'.
    color col_positive.
    when 1.
    write: / text-001 color col_positive.
    when 2.
    write: / text-002 color col_negative.
    exit.
    when 3.
    write: / text-003 color col_negative.
    exit.
    when 4.
    write: / text-004 color col_negative.
    exit.
    when others.
    write: / text-005 color col_negative.
    exit.
    endcase.
    ENDIF.
    ENDFORM. " convert_spool_to_pdf
    *& Form delete_spool_job
    text
    --> p1 text
    <-- p2 text
    FORM delete_spool_job .
    CALL FUNCTION 'RSPO_IDELETE_SPOOLREQ'
    EXPORTING
    spoolreq = spoolreq1
    IMPORTING
    RC =
    STATUS =
    EXCEPTIONS
    error = 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.
    ENDFORM. " delete_spool_job
    *& Form ASSIGN_DATA_4_MAIL
    text
    --> p1 text
    <-- p2 text
    FORM assign_data_4_mail .
    Text content of the mail
    move 'Purchase order: ' to objtxt.
    append objtxt.
    move verkf to objtxt.
    append objtxt.
    move lfa1-name1 to objtxt.
    append objtxt.
    concatenate lfa1-ort01 lfa1-pstlz
    into objtxt separated by space.
    append objtxt.
    clear: objtxt.
    append objtxt.
    append objtxt.
    CLEAR objtxt.
    CONCATENATE 'Purchase Order - ' docno
    ' has been released.'
    INTO objtxt SEPARATED BY space.
    APPEND objtxt.
    clear: objtxt.
    append objtxt.
    append objtxt.
    MOVE ' ' TO objtxt.
    APPEND objtxt.
    clear: objtxt.
    append objtxt.
    append objtxt.
    concatenate 'Note:- This is an automatic mail sender.'
    ' Please do not reply to this mail ID.'
    into objtxt.
    append objtxt.
    concatenate
    ' Any query, please send the mail to the respective buyer'''
    's mail id.' into objtxt.
    append objtxt.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
    EXPORTING
    input = docno
    IMPORTING
    output = docno.
    TLINE format will be coverted as 255 char foramt
    CALL FUNCTION 'QCE1_CONVERT'
    TABLES
    t_source_tab = pdf
    t_target_tab = objbin
    EXCEPTIONS
    convert_not_possible = 1
    OTHERS = 2.
    DESCRIBE TABLE objtxt LINES tab_lines.
    creation of the entry for the compressed document
    CLEAR objpack.
    objpack-transf_bin = ''.
    objpack-head_start = 1.
    objpack-head_num = 0.
    objpack-body_start = 1.
    objpack-body_num = tab_lines.
    objpack-doc_type = 'RAW'.
    objpack-doc_size = ( tab_lines - 1 ) * 255 + STRLEN( objtxt ).
    APPEND objpack.
    creation of the entry for the Attachemnt
    DESCRIBE TABLE objbin LINES tab_lines.
    objpack-transf_bin = 'X'.
    objpack-head_start = 1.
    objpack-head_num = 1.
    objpack-body_start = 1.
    objpack-body_num = tab_lines.
    objpack-doc_type = 'PDF'.
    CONCATENATE docno '.PDF' INTO objpack-obj_name.
    objpack-obj_descr = objpack-obj_name.
    objpack-doc_size = ( tab_lines - 1 ) * 255 + STRLEN( objbin ).
    APPEND objpack.
    For Object Header
    CONCATENATE docno '.PDF' INTO objhead.
    APPEND objhead.
    doc_chng-doc_size = ( tab_lines - 1 ) * 255 + STRLEN( objbin ).
    CONCATENATE 'Purchase Order - ' docno ' has been released'
    INTO doc_chng-obj_descr.
    doc_chng-obj_prio = 1.
    recipient Details
    CLEAR reclist1.
    CLEAR reclist.
    REFRESH reclist1.
    REFRESH reclist.
    SELECT SINGLE * FROM t024
    WHERE t024~mandt = sy-mandt
    AND ekgrp = t_ekgrp.
    reclist1-receiver = t024-smtp_addr.
    reclist1-rec_type = 'U'.
    reclist1-com_type = 'INT'.
    reclist1-receiver = '[email protected]'.
    modify table reclist transporting rec_type receiver COM_TYPE .
    where rec_type is initial.
    APPEND reclist1 TO reclist.
    ENDFORM. " ASSIGN_DATA_4_MAIL
    *& Form send_mail_with_attachment
    text
    --> p1 text
    <-- p2 text
    FORM send_mail_with_attachment.
    sending the document
    CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
    EXPORTING
    document_data = doc_chng
    put_in_outbox = 'X'
    commit_work = 'X'
    TABLES
    packing_list = objpack
    object_header = objhead
    contents_bin = objbin
    contents_txt = objtxt
    receivers = reclist
    EXCEPTIONS
    too_many_receivers = 1
    document_not_sent = 2
    operation_no_authorization = 4
    OTHERS = 99.
    CASE sy-subrc.
    WHEN 0.
    PERFORM flush_mail.
    message 'Mail sent successfully' type 'I'.
    when 1.
    message 'No authorization for sending to the specified number'
    *type 'E'.
    when 2.
    message 'Document could not be sent to any recipient' type 'E'.
    when 4.
    message 'No send authorization' type 'E'.
    when others.
    message 'Error occurred while sending' type 'E'.
    ENDCASE.
    ENDFORM. " send_mail_with_attachment
    Start new screen *
    FORM bdc_dynpro USING program dynpro.
    CLEAR bdcdata.
    bdcdata-program = program.
    bdcdata-dynpro = dynpro.
    bdcdata-dynbegin = 'X'.
    APPEND bdcdata.
    ENDFORM. "bdc_dynpro
    Insert field *
    FORM bdc_field USING fnam fval.
    CLEAR bdcdata.
    bdcdata-fnam = fnam.
    bdcdata-fval = fval.
    APPEND bdcdata.
    ENDFORM. "bdc_field
    *& Form AUTOMATE
    text
    --> p1 text
    <-- p2 text
    FORM flush_mail .
    PERFORM bdc_dynpro USING 'SAPMSSY0' '0120'.
    PERFORM bdc_field USING 'BDC_OKCODE'
    '=PDIA'.
    PERFORM bdc_dynpro USING 'SAPLSPO4' '0300'.
    PERFORM bdc_field USING 'BDC_OKCODE'
    '=FURT'.
    PERFORM bdc_field USING 'BDC_CURSOR'
    'SVALD-VALUE(01)'.
    PERFORM bdc_field USING 'SVALD-VALUE(01)'
    'int'.
    PERFORM bdc_dynpro USING 'SAPMSSY0' '0120'.
    PERFORM bdc_field USING 'BDC_OKCODE'
    '=BACK'.
    PERFORM bdc_dynpro USING 'SAPMSSY0' '0120'.
    PERFORM bdc_field USING 'BDC_OKCODE'
    '=BACK'.
    CALL TRANSACTION 'SCOT' USING bdcdata
    MODE 'N'
    UPDATE 'S'.
    ENDFORM. " AUTOMATE
    regards,
    Latheesh

Maybe you are looking for

  • My Verizon Nightmare - Be weary of poorly trained Verizon employees in the Costco kiosks

    A few days ago my week old HTC Droid Incredible 4g LTE that I purchased at Costco developed a circular blob of yellow discoloration on the lower-left portion of the screen in the area right above the micro-USB port. It seemed to get darker while conn

  • Sales Order Posting

    Hi Expert, I have seen that in the pricing procedure of sales order there are some account keys for accrual are assigned to the condition types. I believe with them the system will create entries to corresponding G/L account automatically the time th

  • HELP REQUIRED in ALV

    I am using function module ALV. I need a add a box on the side which comes in ALV. Second i need to control it such that the person can either select one record or mutilple. I know for getting the box there is a field in the layout. Help in this rega

  • PHP/MySQL Relational Database

    Hi, I am fairly new to php/MySQL. I am stuck on how to make a cross linking database. I have two tables "users" and "comments" and would like to set up a page that a logged in user can see and edit the comments they have made. So far I have tried to

  • Some of the newer shows and movies on my IPAD 2 show "cannot open content not authorized"

    All of my library plays on my MAC and Apple TV, but some of the newer shows and movies on my IPAD 2 show "cannot open content not authorized" . If I download them directly to my IPAD they will play. iPad and MAC are all up to date. I have restarted t