OLE2 Automation

Hello, could anybody specify any links about using OLE2 automation in Oracle Forms 4.5.
Thank you in advance.
Anita.

You can search for OLE in this forum or you can go through the OLE demo form in the Forms Demos.
Partha
null

Similar Messages

  • Correct Text Using OLE2 Automation

    Hello!
    I have an application based on forms 4.5 and I want to correct a text in an text item using ole2 automation.I already have an ole container associated with a spell checker.
    How do i send the text in the text item to the ole container?
    Please help me.
    Thanks.

    You can search for OLE in this forum or you can go through the OLE demo form in the Forms Demos.
    Partha
    null

  • OLE2 Automation & Word 2000

    I am trying to figure out why the following does not work. The search and replace values are substituted but the replacement does not actually take place - its almost asif another method/event needs to be tirggered, but for the life of me I cannot figure out what it is
    Answers appreciated !!
    Andrew
    =================================
    procedure run_word (document varchar2) is
    lArgs OLE2.LIST_TYPE;
    findrepl OLE2.OBJ_TYPE;
    objword OLE2.OBJ_TYPE;
    BEGIN
    objWord := OLE2.CREATE_OBJ('WORD.Basic');
    lArgs := OLE2.CREATE_ARGLIST;
    OLE2.ADD_ARG(lArgs,document);
    OLE2.INVOKE(objWord, 'fileopen',lArgs);
    OLE2.Invoke(objWord, 'AppActivate');
    OLE2.Invoke(objWord, 'AppShow');
    OLE2.DESTROY_ARGLIST(lArgs);
    /* Original VB Code
    Selection.Find.ClearFormatting
    Selection.Find.Replacement.ClearFormatting
    With Selection.Find
    .Text = "CNAME"
    .Replacement.Text = "Andrew"
    .Forward = False
    .Wrap = wdFindAsk
    .Format = False
    .MatchCase = False
    .MatchWholeWord = False
    .MatchWildcards = False
    .MatchSoundsLike = False
    .MatchAllWordForms = False
    End With
    Selection.Find.Execute Replace:=wdReplaceAll
    End Sub
    lArgs := OLE2.CREATE_ARGLIST;
    OLE2.ADD_ARG(lArgs, 'CNAME');
    OLE2.ADD_ARG(lArgs, 'Andrew');
    OLE2.ADD_ARG(lArgs, 0);
    OLE2.ADD_ARG(lArgs, 0);
    OLE2.ADD_ARG(lArgs, 0);
    OLE2.ADD_ARG(lArgs, 0);
    OLE2.ADD_ARG(lArgs, 0);
    OLE2.ADD_ARG(lArgs, 0);
    OLE2.ADD_ARG(lArgs, 0);
    OLE2.ADD_ARG(lArgs, 0);
    findrepl := OLE2.INVOKE_OBJ(objWord, 'EditReplace',lArgs);
    OLE2.DESTROY_ARGLIST(lArgs);
    END;
    null

    I'm experiancing the same problem.
    I wonder if you have salved the problem in already
    With kind recards

  • OLE Automation to Excel problem

    Hello All,
    In a report program I have used the OLE2 automation to download data into Excel. But it's not functioning. Its doing nothing. Could you tell me do I have to have any authorizations to use this? Otherwise what could be the problem?
    Plz advise.
    Thanks a lot.

    Thnx Rich.
    Here's the code:
    <b>REPORT ZMR_MAX_PERIOD.
    *-- Tables----
    tables: mara,                           "General Material Data
            marc,                           "Plant Data for Material
            makt.                           "Material Descriptions
    *-- Data of OLE
    include ole2incl.
    data: GS_EXCEL type ole2_object,
          GS_BOOKS type ole2_object,
          GS_WBOOK type ole2_object,
          GS_SHEET type ole2_object,
          GS_PAGE  type ole2_object,
          GS_RANGE type ole2_object,
          GS_FONT  type ole2_object,
          GS_COLS  type ole2_object,
          GS_CELL  type ole2_object.
    *-- Variables----
    *-- Offsets for output columns
    data:      w_wid01   type i,
               w_wid02   type i,
               w_wid03   type i,
               w_wid04   type i,
               w_wid05   type i,
               w_wid06   type i,
               w_wid07   type i,
               w_wid08   type i,
               w_wid09   type i,
               w_wid10   type i,
               w_wid11   type i,
               w_wid12   type i,
               w_wid13   type i,
               w_wid14   type i,
               w_wid15   type i,
               w_wid16   type i,
               w_wid17   type i,
               w_color(1).                  "for background color
    *-- Constants----
    *-- Column widths for report output
    constants: c_space   type i value  0,
               c_wid01   type i value  1,
               c_wid02   type i value  6,
               c_wid03   type i value  1,
               c_wid04   type i value 15,
               c_wid05   type i value  1,
               c_wid06   type i value 19,
               c_wid07   type i value  1,
               c_wid08   type i value 42,
               c_wid09   type i value  1,
               c_wid10   type i value 21,
               c_wid11   type i value  1,
               c_wid12   type i value 10,
               c_wid13   type i value  1,
               c_wid14   type i value 12,
               c_wid15   type i value  1,
               c_wid16   type i value 17,
               c_wid17   type i value  1.
    *-- Internal tables----
    *-- Internal table for material data
    data: begin of i_material occurs 0,
            matnr like mara-matnr,
            mtart like mara-mtart,
            aenam like mara-aenam,
            laeda like mara-laeda,
            werks like marc-werks,
            maxlz like marc-maxlz,
            lzeih like marc-lzeih,
            maktx like makt-maktx,
          end of i_material.
    *-- Internal table for output
    data: begin of i_output occurs 0,
           werks like marc-werks,           "Plant
           mtart like mara-mtart,           "Material type
           matnr like mara-matnr,           "Material number
           maktx like makt-maktx,           "Material description
           maxlz like marc-maxlz,           "Maximum storage period
           lzeih like marc-lzeih,           "Unit for maximum storage period
           aenam like mara-aenam,           "User changed the object
           laeda like mara-laeda,           "Last changed on
         end of i_output.
    SELECTION-SCREEN DEFINITION
    *-- Data Selection
    selection-screen begin of block b1 with frame title title1.
    select-options: s_matnr for mara-matnr,
                    s_werks for marc-werks,
                    s_lgpro for marc-lgpro,
                    s_mtart for mara-mtart.
    selection-screen end of block b1.
    AT SELECTION-SCREEN VALIDATIONS
    at selection-screen.
    *--Check Plant is entered
    if s_werks is initial.
    message e009(zm) with 'please enter plant'.
    endif.
    INITIALIZATION
    initialization.
    *-- initialize text fields for selection-screen
      title1 = 'Material Data'.
      title2 = 'File locations'.
      perform assign_column_widths.
    START-OF-SELECTION (Required in 4.6)
    start-of-selection.
      set pf-status 'MAIN'.
    *-- Perform get data
      perform get_data.
    *-- Populate data into output tab
      perform populate_data.
    *-- Write output list
      perform write_output.
    END-OF-SELECTION
    TOP-OF-PAGE
    TOP OF PAGE AT LINE SELECTION
    AT LINE SELECTION
    AT USER COMMAND
    at user-command.
    *-- Download to Excel
       case sy-ucomm.
         when 'EXCEL'.
          perform download_to_excel.
       endcase.
    --S-U-B-R-O-U-T-I-N-E-S--
        FORM SET_BACKGROND_COLOR
    Set background color for list output
    form set_background_color.
      if w_color = 1.
         FORMAT INTENSIFIED OFF COLOR 2.
         clear w_color.
      else.
         FORMAT INTENSIFIED ON COLOR 2.
         w_color = 1.
      endif.
    endform.                           "set_background_color
        FORM GET_DATA
    Get material data
    form get_data.
      CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
       EXPORTING
         TEXT             = 'reading material data... '
        select mara~matnr
               mara~mtart
               mara~aenam
               mara~laeda
               marc~werks
               marc~maxlz
               marc~lzeih
               makt~maktx
          into table i_material
          from mara
          join marc
            on maramatnr = marcmatnr
          join makt
            on marcmatnr = maktmatnr
         where mara~matnr IN s_matnr
           and marc~werks IN s_werks
           and marc~lgpro IN s_lgpro
           and mara~mtart IN s_mtart.
        sort i_material by matnr.
    endform.                           "get_data
        FORM POPULATE_DATA
    Populate data for output
    form populate_data.
      CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
       EXPORTING
         TEXT             = 'Processing data... '
    loop at i_material.
       move i_material-werks to i_output-werks.
       move i_material-mtart to i_output-mtart.
       move i_material-matnr to i_output-matnr.
       move i_material-maktx to i_output-maktx.
       move i_material-maxlz to i_output-maxlz.
       move i_material-lzeih to i_output-lzeih.
       move i_material-aenam to i_output-aenam.
       move i_material-laeda to i_output-laeda.
       append i_output.
       clear  i_output.
    endloop.
    sort i_output by matnr.
    endform.                           "populate_data
        FORM WRITE_COLUMN_HEADINGS
    Write column headings for output
    form write_column_headings.
      CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
       EXPORTING
         TEXT             = 'Writing output... '
       if i_output[] is initial.
         message i000.
         exit.
       endif.
    *-- Write column headings
    skip.
    uline.
    FORMAT COLOR 1 ON.
    write: at /w_wid01 sy-vline.
    write: at /w_wid02(c_wid02) 'Plant' CENTERED,
           at  w_wid03(c_wid03) SY-VLINE,
           at  w_wid04(c_wid04) 'Material Type' CENTERED,
           at  w_wid05(c_wid05) SY-VLINE,
           at  w_wid06(c_wid06) 'Material Number' CENTERED,
           at  w_wid07(c_wid07) SY-VLINE,
           at  w_wid08(c_wid08) 'Material Description' CENTERED,
           at  w_wid09(c_wid09) SY-VLINE,
           at  w_wid10(c_wid10) 'Max. Storage Period' CENTERED,
           at  w_wid11(c_wid11) SY-VLINE,
           at  w_wid12(c_wid12) 'Time Unit' CENTERED,
           at  w_wid13(c_wid13) SY-VLINE,
           at  w_wid14(c_wid14) 'Changed By' CENTERED,
           at  w_wid15(c_wid15) SY-VLINE,
           at  w_wid16(c_wid16) 'Last Changed On' CENTERED,
           at  w_wid17(c_wid17) SY-VLINE.
    FORMAT COLOR 1 OFF.
    uline.
    endform.                           "write_column_headings
        FORM WRITE_OUTPUT
    Write list output
    form write_output.
    loop at i_output.
        perform set_background_color.
      write: at /w_wid01(c_wid01) SY-VLINE,
             at  w_wid02(c_wid02) i_output-werks,
             at  w_wid03(c_wid03) SY-VLINE,
             at  w_wid04(c_wid04) i_output-mtart,
             at  w_wid05(c_wid05) SY-VLINE,
             at  w_wid06(c_wid06) i_output-matnr,
             at  w_wid07(c_wid07) SY-VLINE,
             at  w_wid08(c_wid08) i_output-maktx,
             at  w_wid09(c_wid09) SY-VLINE,
             at  w_wid10(c_wid10) i_output-maxlz,
             at  w_wid11(c_wid11) SY-VLINE,
             at  w_wid12(c_wid12) i_output-lzeih,
             at  w_wid13(c_wid13) SY-VLINE,
             at  w_wid14(c_wid14) i_output-aenam,
             at  w_wid15(c_wid15) SY-VLINE,
             at  w_wid16(c_wid16) i_output-laeda,
             at  w_wid17(c_wid17) SY-VLINE.
    endloop.
    endform.                           "write_output
        FORM DOWNLOAD_TO_EXCEL
    Download report data to excel spreadsheet
    form download_to_excel.
    data: row type i value '2'.
    *-- Create Excel spreadsheet
      create object GS_EXCEL 'EXCEL.APPLICATION'.
       if sy-subrc <> 0.
         message e002(sy) with sy-msgli.
       endif.
       call method of GS_EXCEL 'WORKBOOKS' = GS_BOOKS.
       call method of GS_BOOKS 'ADD' = GS_WBOOK.
    *-- Add column headers
       perform fill_cell using 1 1 'Plant'.
       perform fill_cell using 1 2 'Material Type'.
       perform fill_cell using 1 3 'Material Number'.
       perform fill_cell using 1 4 'Material Description'.
       perform fill_cell using 1 5 'Max Storage'.
       perform fill_cell using 1 6 'Time Unit'.
       perform fill_cell using 1 7 'Changed By'.
       perform fill_cell using 1 8 'Last Changed On'.
    loop at i_output.
       perform fill_cell using row 1 i_output-werks.
       perform fill_cell using row 2 i_output-mtart.
       perform fill_cell using row 3 i_output-matnr.
       perform fill_cell using row 4 i_output-maktx.
       perform fill_cell using row 5 i_output-maxlz.
       perform fill_cell using row 6 i_output-lzeih.
       perform fill_cell using row 7 i_output-aenam.
       perform fill_cell using row 8 i_output-laeda.
       row = row + 1.
    endloop.
    *-- Set name of spreadsheet
      call method of GS_EXCEL 'ACTIVESHEET' = GS_SHEET.
      set property of GS_SHEET 'NAME' = 'Max Storage Period'.
    *-- Set orientaion to landscape.
      call method of GS_SHEET 'PAGESETUP' = GS_PAGE.
      set property of GS_PAGE 'ORIENTATION' = 2.
      free object GS_PAGE.
    *-- Make column headers bold and centered
      call method of GS_SHEET 'RANGE' = GS_RANGE exporting #1 = 'A1:Z1'.
      set property of GS_RANGE 'HORIZONTALALIGNMENT' = 3.
      call method of GS_RANGE 'FONT' = GS_FONT.
      set property of GS_FONT 'BOLD' = 1.
      free object GS_RANGE.
      free object GS_FONT.
    *-- Set column widths to autofit
      call method of GS_SHEET 'RANGE' = GS_RANGE exporting #1 = 'A1:Z1'.
      set property of GS_RANGE 'COLUMNS' = GS_COLS.
      call method of GS_COLS 'AUTOFIT'.
    *-- Display spreadsheet
      set property of GS_EXCEL 'VISIBLE' = 1.
    *-- Free OLE objects
      free object GS_EXCEL.
      free object GS_BOOKS.
      free object GS_WBOOK.
      free object GS_SHEET.
      free object GS_RANGE.
      free object GS_COLS.
      free object GS_CELL.
    endform.                           "download_to_excel
        FORM FILL_CELL
    Add report fields to Excel sheet
    form fill_cell using row col value.
    call method of GS_EXCEL 'CELLS' = GS_CELL exporting #1 = row
                                                   #2 = col.
    set property of GS_CELL 'VALUE' = VALUE.
    free object GS_CELL.
    endform.
    ----</b>

  • Blob (bfile)+ ole2

    hello gurus
    i would like to know how is possible within Oracle Forms (i am still using 6i) to retrieve a MS office document stored in an oracle DB and showing it using ole2 automation.
    I miss just the step of retrieving from DB and loading it into memory or somewhere on the client filesystem, so let it be opened with the right MS office application (chosen with ole2)
    My actual idea is to create a block based on the table that stores the blob (bfile) column, but i don't know how to store the blob (bfile) object in the forms application.. there is a particular object to use? or i must just load the key (or rowid) and then requering the table using it? and after loading the blob (bfile) from table, how can i convert it to be usable for ole2?
    thanks in advance!
    claudio

    Chapter 7 in the Oracle Call Interface Programmer's Guide discusses [LOB and BFILE operations|http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14250/oci07lob.htm#g452677]. Given that you are posting here, I assume you are interested in using the OCI interface and that you are familiar with the basics of OCI programming. If not, you'll want to read the other chapters in the OCI Programmer's Guide.
    Justin

  • Why does not work OLE2 on ITS?

    Hi
    I created SAP module pool program with OLE2. This program read data from control and set into word template - create word document. This program work perfect.
    I generated ITS program from my module pool using this manual
    http://www.riyaz.net/sap/developing-web-transactions-in-its-part-i/434/
    ITS program work, but with some restriction.
    Does not work or not show:
    OLE2
    MESSAGE
    SEARCH HELP
    Can you help me how solve these prolems?
    It is possible work OLE with ITS?
    How template it is perfects for work with dynamics data?
    http://help.sap.com/saphelp_nw04s/helpdata/en/70/57950ca7c611d3961700a0c94260a5/content.htm
    Classical, HTML business or WebGUI?
    Thank you

    I check code what give an error and:
    this part
    CREATE OBJECT gs_app 'WORD.APPLICATION'.
    SY-SUBRC -> 2
    CREATE OBJECT in OLE2 sets SY-SUBRC to 0 if an external object could be created, otherwise to 1, 2, or 3, depending on the cause.
    OLE2 Automation, executed successfully, otherwise 1, 2, 3, or 4, depending on the cause of the error.
    SY-SUBRC = 2:  SAP GUI function call error. The front-end ports of SAP’s OLE implementation modules are implemented only under Microsoft Windows and Apple Macintosh.

  • Download alv-table to MS-Word using OLE2

    Hello,
    I need to download an internal table like ALV to MS-Word using OLE2.
    thank you 4 ur help.
    I fund this Report, but here i just can write a text in word but I can not show/write a Table.
    http://wiki.sdn.sap.com/wiki/display/Snippets/SampleprogramtocreateaWorddocumentfromABAP%28usingOLE%29
    CALL METHOD OF v_objselection 'TypeText'
      EXPORTING #1 = 'Olé World!'.
    when i wrote a table 4 Exmpel lt_outab insteat of 'Ole World' I got a trouble during compling because lt_outab is not a CHAR:-(

    I recommend reading this article:
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/204d1bb8-489d-2910-d0b5-cdddb3227820
    You will get all the information you need to do with OLE2 Automation.
    It is also useful to dig into VB a little bit.
    In the article on page 7 you have a sample code which shows how to do with tables. You need to loop in ABAP on the internal table and inside this loop you need to loop on fields. Use VB methods ADD and CELL.
    FIELD-SYMBOLS: <wrk> LIKE LINE OF itab, <field> TYPE ANY.
    CALL METHOD OF word 'Add' = table
      EXPORTING
        #1 = range_table
        #2 = lines                            "lines( itab )
        #3 = fields.                          "number of fields
    LOOP AT itab ASSIGNING <wrk>.
      l_index = sy-tabix.
      DO.
        ASSIGN COMPONENT sy-index OF STRUCTURE <wrk> TO <field>.
        IF sy-subrc NE 0.
          EXIT.
        ENDIF.
        CALL METHOD OF word 'Cell' = cell
          EXPORTING
            #1 = l_index
            #2 = sy-index.
        GET PROPERTY OF cell 'Range' = range
        SET PROPERTY OF range 'Text' = <field>.
      ENDDO.
    ENDLOOP.
    Regards
    Edited by: Krzysztof Usowicz on Sep 15, 2010 9:45 AM

  • Generating Excel Sheet from Reports ......

    Hi,
    I want to generate reports both in Oracle Reports 6.0, as well
    as in Microsoft Excel. The simplest solution I thought was to
    generate the Oracle Report first and then, give a button on the
    report, which when pressed, can scan the data in the generated
    report and write it into an Excel file. The writing part to
    Excel file, I can do by using the OLE2 automation. I am not able
    to find a way to read the data in the generated report
    programatically. Is this possible and if yes, then can anyone
    suggest me a way to do this. Is there an alternate solution to
    this problem.
    regards,
    Abhilash

    Hi ,
    Modified your code .
    public void generate(IPortalComponentRequest request) throws Exception {
    HSSFWorkbook wb = new HSSFWorkbook();
    HSSFSheet sheet = wb.createSheet();
    HSSFRow row = sheet.createRow(3);
    HSSFCell cell = row.createCell((short)0);
    HSSFCellStyle cs1 = wb.createCellStyle();
    HSSFCellStyle cs2 = wb.createCellStyle();
    HSSFCellStyle cs3 = wb.createCellStyle();
    HSSFDataFormat df = wb.createDataFormat();
    HSSFFont f = wb.createFont();
    HSSFFont f2 = wb.createFont();
    f.setFontHeightInPoints((short) 12);
    f2.setFontHeightInPoints((short) 10);
    cs1.setFont(f);
    cs1.setDataFormat(df.getFormat("#,##0.0"));
    cs2.setFont(f2);
    cell.setCellValue(1);
    row.createCell((short)1).setCellValue(1.2);
    row.createCell((short)2).setCellValue("This is a string");
    row.createCell((short)3).setCellValue(true);
    HttpServletResponse res = request.getServletResponse(true);
    try {
    res.setContentType("application/vnd.ms-excel");
    wb.write(res.getOutputStream());
    }catch(Exception e) {}
    Check this blog for more
    Create an excel file from JAVA using HSSF api

  • How to Search for text in a word document and replace it

    Hey All ,
    I am able to open up a word document present locally using OLE2 Automation. Now i need to search for a text in that document
    and replace it with another text. How do i achieve this?
    And another issue is when i search for the particular pattern i need to store the pattern that comes after the pattern as i need it for further use before i replace it.
    Thanks And Warm Regards,
    Nischal

    Hey Chen,
    Well before i do the search and edit , I am actually opening a .mts file in word which is happening successfully.
    The issue that i am facing now is I am unable to save it as .doc file through the 'SaveAs' method.
    Here is my code. Can u please tell me what i need to do in order to correct this.
    After i do this conversion i intend to pass the data from the .doc file to an internal table and then do the required change.
    But First i need to save it to .doc type.
    REPORT  MAIN_PROGRAM_2.
    INCLUDE OLE2INCL.
    *Declaration Of OLE2_Object Variables.
    DATA: WORD            TYPE OLE2_OBJECT,
          DOCUMENTS       TYPE OLE2_OBJECT,
          ACT_DOCUMENTS   TYPE OLE2_OBJECT.
    *Declaration of variables
    PARAMETERS PATH       TYPE string.
    DATA:Relative_Path    TYPE string,
         Relative_Path_Save    TYPE string.
    *Declaration of an internal table
    CONCATENATE PATH '\Script.mts' INTO RELATIVE_PATH.
    *Object Creation in order for us to open word
    CREATE OBJECT WORD 'WORD.APPLICATION'.
    PERFORM ERROR_HANDLE.
    *Set visibility property of MS word.
    SET property of WORD 'VISIBLE' = 1.
    *Open A document
    CALL METHOD OF WORD 'Documents' = DOCUMENTS.
    PERFORM ERROR_HANDLE.
    *CALL METHOD OF DOCUMENTS 'ADD' = ACT_DOCUMENTS.
    CALL METHOD OF DOCUMENTS 'OPEN' EXPORTING #1 = RELATIVE_PATH.
    PERFORM ERROR_HANDLE.
    *GET PROPERTY OF WORD 'ActiveDocument' = ACT_DOCUMENTS.
    *PERFORM ERROR_HANDLE.
    **To save the script.mts to script .doc file in order to put it into an internal table
    CONCATENATE PATH '\Script.doc' INTO RELATIVE_PATH_SAVE.
    CALL METHOD OF WORD 'SaveAs' EXPORTING #1 = RELATIVE_PATH_SAVE.
    PERFORM ERROR_HANDLE.
    FREE OBJECT WORD.
    The Save part of the code is giving me an OLE error = 2
    Thanks And Kind Regards,
    Nischal
    Edited by: Nischal HP on Apr 28, 2011 1:53 PM

  • RE: 4 Forte questions, sitting in a row

    Hi Carl,
    a. With regards to Forte "wrappering". Presumably the 'C' program that
    you want to interface to, must have an API that you can access, and then
    you call those functions from within Forte ?
    If its a vanilla C program (you need the *.obj file) its quite straightforward. You create a Forte project with an appropriately named class and method stubs in an editor (not in Forte). This then gets imported into Forte and partitioned as an external library. Forte then generates the appropriate C++ stubs, which you compile with the appropriate C++ compiler. This will link the desired C program into your Forte generated C++ stubs and all is well. If its a C++ program, typically they are DLL's, or if you don't have the *.obj file, you have to jump through some (more) hoops as another user put it. Then you need to write a C (not C++) program that calls the desired C++ DLL. And repeat as above. So you then end up with 2 sets of stubs. Its quite cumbersome, but it does work !
    b. How does Forte support external, real-time, interrupt driven
    applications ?
    I'm not sure I uderstand the question - possibly the same as answer to d below.
    c. Does Forte support 'Business Objects' datamining tool, and if not,
    does it support any other data mining tool ?
    As far as I know it does support Business Objects. At the interface level Forte supports the C API or OLE2 automation (and next version (3) will support Active-X as well) and most API's will give you one of those options.
    d. Apparently Forte can interface to external applications using
    messages, like it does internally between objects. How can it do this ?
    Interfacing to external objects can done via three mechanisms :
    1. CORBA. It uses the DEC ORB to interface fully to CORBA 2 compliant clients (from Forte SO's) or servers (from Forte client partitions).
    2. DCE. Similar to above
    3. The ExternalConnection Class (Framework) is probably the easiest. We have just received the documentation and it looks really good. Essentially you open a TCP/IP pipe to another process on which you can both send and receive raw data. You obviously need to design some higher level coding scheme, but it looks very straightforward to implement and from what I know of TCP/IP pipes its the best performing interface mechanism. In answer to your earlier question, realtime external interrupts would probably work best with this. In fact I know of implementations where they are busy doing exactly this with continous datafeeds (and machine PLC control) via their own (!!) C-wrappered Unix pipes interface.
    Any insight would be appreciated,
    - Carl
    Carl Schei | Dexel (Pty) Ltd (Durban) |
    Software Engineer | Tel : 27 31 2669273 |
    email : [email protected] | Fax : 27 31 2660340 |
    ----------------------------------------------------------------

    Do you have the side vibrate/ring switch fully engaged in one direction or the other?  If so, then it very well could be a hardware issue with the switch.  Visit to an Apple store genius bar would not be a bad idea to have it checked by the techs.

  • Non-Delivery of:RE: 4 Forte questions, sitting in arow

    Hi Carl,
    a. With regards to Forte "wrappering". Presumably the 'C' program that
    you want to interface to, must have an API that you can access, and then
    you call those functions from within Forte ?
    If its a vanilla C program (you need the *.obj file) its quite straightforward.
    You create a Forte project with an appropriately named class and method stubs
    in an editor (not in Forte). This then gets imported into Forte and partitioned
    as an external library. Forte then generates the appropriate C++ stubs, which
    you compile with the appropriate C++ compiler. This will link the desired C
    program into your Forte generated C++ stubs and all is well. If its a C++
    program, typically they are DLL's, or if you don't have the *.obj file, you
    have to jump through some (more) hoops as another user put it. Then you need to
    write a C (not C++) program that calls the desired C++ DLL. And repeat as
    above. So you then end up with 2 sets of stubs. Its quite cumbersome, but it
    does work !
    b. How does Forte support external, real-time, interrupt driven
    applications ?
    I'm not sure I uderstand the question - possibly the same as answer to d below.
    c. Does Forte support 'Business Objects' datamining tool, and if not,
    does it support any other data mining tool ?
    As far as I know it does support Business Objects. At the interface level Forte
    supports the C API or OLE2 automation (and next version (3) will support
    Active-X as well) and most API's will give you one of those options.
    d. Apparently Forte can interface to external applications using
    messages, like it does internally between objects. How can it do this ?
    Interfacing to external objects can done via three mechanisms :
    1. CORBA. It uses the DEC ORB to interface fully to CORBA 2 compliant clients
    (from Forte SO's) or servers (from Forte client partitions).
    2. DCE. Similar to above
    3. The ExternalConnection Class (Framework) is probably the easiest. We have
    just received the documentation and it looks really good. Essentially you open
    a TCP/IP pipe to another process on which you can both send and receive raw
    data. You obviously need to design some higher level coding scheme, but it
    looks very straightforward to implement and from what I know of TCP/IP pipes
    its the best performing interface mechanism. In answer to your earlier
    question, realtime external interrupts would probably work best with this. In
    fact I know of implementations where they are busy doing exactly this with
    continous datafeeds (and machine PLC control) via their own (!!) C-wrappered
    Unix pipes interface.
    Any insight would be appreciated,
    - Carl
    Carl Schei | Dexel (Pty) Ltd (Durban) |
    Software Engineer | Tel : 27 31 2669273 |
    email : [email protected] | Fax : 27 31 2660340 |
    ------ Message Header Follows ------
    Received: from pebble.Sagesoln.com by notes.bsginc.com
    (PostalUnion/SMTP(tm) v2.1.9c for Windows NT(tm))
    id AA-1996Sep20.134600.1787.19161; Fri, 20 Sep 1996 13:46:02 -0500
    Received: (from sync@localhost) by pebble.Sagesoln.com (8.6.10/8.6.9) id
    JAA13740 for forte-users-outgoing; Fri, 20 Sep 1996 09:40:31 -0700
    Received: (from uucp@localhost) by pebble.Sagesoln.com (8.6.10/8.6.9) id
    JAA13734 for <[email protected]>; Fri, 20 Sep 1996 09:40:29 -0700
    Received: from lin01.global.co.za(196.3.164.2) by pebble.sagesoln.com via smap
    (V1.3)
    id sma013732; Fri Sep 20 09:40:12 1996
    Received: from anx_99.global.co.za (anx_99.global.co.za [196.3.168.109]) by
    lin01.global.co.za (8.7.3/8.7.3) with SMTP id SAA14527; Fri, 20 Sep 1996
    18:38:14 -0200 (GMT)
    Received: by anx_99.global.co.za with Microsoft Mail
    id <01BBA723.B4E4AD40@anx_99.global.co.za>; Fri, 20 Sep 1996 18:44:08 +-200
    Message-ID: <01BBA723.B4E4AD40@anx_99.global.co.za>
    From: Anton van Niekerk <[email protected]>
    To: "'Dexel - Durban'" <[email protected]>
    Cc: "'Forte user group'" <[email protected]>
    Subject: RE: 4 Forte questions, sitting in a row
    Date: Fri, 20 Sep 1996 18:39:50 +-200
    MIME-Version: 1.0
    Content-Type: text/plain; charset="us-ascii"
    Content-Transfer-Encoding: quoted-printable
    Sender: [email protected]
    Precedence: bulk
    Reply-To: [email protected]

    -Your IP number is not blacklisted in the majr blacklist (doesn't mean this is true for all, but you should be OK=
    -Your mail server is not an open relay, but is also not particularly well configured (nothing you can do about other than change provider).
    This means, that it is close to impossible to tell you where the problem is from distance. I have never heard of your ISP so I cannot express any opinion.
    If things are like you explained in points 1 and 2 of your post, chances are your ISPs mailserver has a very aggressive spamfilter generating false positives or has some other major configuration issue.
    Do you have to authenticate to send mail?
    Can you please reply to the testmail I sent you, so I can check it from my side.
    Alex
    P.S. Point 4 of your original post is part of life in the internet. Nothing you can do about. That's what spam filters are for.
    P.P.S. All of this has nothing to do with Mac OS X Server so you are actually in the wrong place. Doesn't matter now as you'll have to have your provider sort this out anyway.

  • Sending E-mail Through Oracle Forms

    Hi all
    what i want is as the following:
    1- i would like to convert the report to the PDF file internally using code.
    2- open the outlook.
    3- attcah the PDF automatically to the e-mail.
    4- finally sending the e-mail though outlook
    could i do that in Oracle forms 6i if i could do that can anyone instruct me to do it step by step

    Oh...it's now called ["My Oracle Support"|https://metalink.oracle.com/] .
    There's a note on "My Oracle Support" on this item.
    This is the note:
    Subject:      OLE AUTOMATION: Example Sending a Mail From Forms to Outlook
           Doc ID:      119828.1      Type:      BULLETIN
           Modified Date :      02-SEP-2008      Status:      PUBLISHED
    PURPOSE
    This document contains a sample code how to send an e-mail from Forms to Outlook
    (97-2000). 
    SCOPE & APPLICATION
    It can be used in addition of the whitepaper "Cracking Outlook!", which explains
    the object model of Outlook in detail.
    (Have a look in the Technical Libaries Folder Forms Whitepaper, their you can
    find it)
    OLE: Forms to Outlook
    Object Model
    "Cracking outlook!" explains the Object Model, you can find additional
    information in the Visual Basic Help of Outlook, which must be installed from
    your Office CD-Rom.  Once installed, you can access the help
    by choosing Tools->Macro->Visual Basic Editor and then go to the Help or
    Object Browser (view -> Object Browser)
    Now you can retrieve the Objects, their Methods and Properties. 
    Eg: the 'Application' Object has the Method 'CreateItem'.
    Note this information is also available in MSDN library or if you require more
    information on this Microsoft has to be contacted.
    OLE2, CLIENT_OLE2 Package
    Once you know the Objects, Methods and Properties you can access them with the
    OLE2 package.  This package provides a PL/SQL API for creating, manipulating,
    and accessing attributes of OLE2 automation objects.  When using OLE2 with
    WebForms every call will be executed on the midtier and not on the client. 
    So alternatively, the CLIENT_OLE2 package can be used, that is delivered by
    Webutil, to execute the OLE code on the client.
    Examples
    Once you know the Outlook Object model and you know the functions of the OLE2
    or CLIENT_OLE2 package you can write your own OLE2/CLIENT_OLE2 code to send a
    mail via Outlook.
    Here below are 2 different ways of sending an email using Outlook. 
    Sample 1:
    OLE2 sample: Here a MailItem is created, then the Recepient is explicitely
    added and resolved.  The mailItem is saved before being sent.
    Declare
    /*declaration of the Outlook Object Variables*/
    application ole2.OBJ_TYPE;     
    hMailItem ole2.OBJ_TYPE;
    hRecipients ole2.OBJ_TYPE;
    recipient ole2.OBJ_TYPE;
    nameSpace OLE2.OBJ_TYPE;
    /*declaration of the argument list*/ 
    args OLE2.LIST_TYPE;          
    begin
    /*create the Application Instance*/
    application:=ole2.create_obj('Outlook.Application');          
    /* create namespace and login */
    args:=ole2.create_arglist;
    ole2.add_arg(args,'MAPI');
    nameSpace:=ole2.invoke_obj(application,'getNameSpace',args);
    ole2.destroy_arglist(args);
    ole2.invoke(nameSpace,'Logon');
    /*create a Mail Instance by calling CreateItem Method and giving argument 0 with
    it,
    you can find the item types in the explanation of the CreateItem Method
    (0=olMailItem,1=olAppointmentItem, ?)*/
    args:=ole2.create_arglist;                         
    ole2.add_arg(args,0);
    hMailItem:=ole2.invoke_obj(application,'CreateItem',args);
    ole2.destroy_arglist(args);
    /*Get the Recipients property of the MailItem object: 
    Returns a Recipients collection that represents all the Recipients for the
    Outlook item*/
    args:=ole2.create_arglist;
    hRecipients:=ole2.get_obj_property(hMailItem,'Recipients',args);
    ole2.destroy_arglist(args);
    /*Use the Add method to create a recipients Instance and add it to the
    Recipients collection*/
    args:=ole2.create_arglist;
    ole2.add_arg(args,'[email protected]');
    recipient:=ole2.invoke_obj(hRecipients,'Add',args);
      /* put the property Type of the recipient Instance  to value needed
    (0=Originator,1=To,2=CC,3=BCC)*/
    ole2.set_property(recipient,'Type',1);
    ole2.destroy_arglist(args);
    /*Resolve the Recipients collection*/
    args:=ole2.create_arglist;
    ole2.invoke(hRecipients,'ResolveAll',args);
    /*set the Subject and Body properties*/
    ole2.set_property(hMailItem,'Subject','Test OLE2 to Outlook');
    ole2.set_property(hMailItem,'Body','this is body text');
    /*Save the mail*/
    ole2.invoke(hMailItem,'Save',args);
    ole2.destroy_arglist(args);
    /*Send the mail*/
    args:=ole2.create_arglist;
    ole2.invoke(hMailItem,'Send',args);
    ole2.destroy_arglist(args);
    /*Release all your Instances*/
    release_obj(hMailItem);
    release_obj(recipient);
    release_obj(hRecipients);
    release_obj(nameSpace);
    release_obj(application);
    end;
    Sample 2
    CLIENT_OLE2 sample.  Here a MailItem is created with an attachment and directly
    sent.
    Declare
    objOutlook CLIENT_OLE2.OBJ_TYPE;
    objMail CLIENT_OLE2.OBJ_TYPE;
    objArg CLIENT_OLE2.LIST_TYPE;
    objAttach CLIENT_OLE2.OBJ_TYPE;
    nameSpace CLIENT_OLE2.OBJ_TYPE;
    BEGIN
    objOutlook := CLIENT_OLE2.CREATE_OBJ('Outlook.Application');
    /* create namespace and login */
    args:=client_ole2.create_arglist;
    client_ole2.add_arg(args,'MAPI');
    nameSpace:=ole2.invoke_obj(objOutlook,'getNameSpace',args);
    client_ole2.destroy_arglist(args);
    client_ole2.invoke(nameSpace,'Logon');
    -- Previous example usually used 'mapi.session' but this doesn't work correctly
    --anymore.
    objarg := CLIENT_OLE2.CREATE_ARGLIST;
    CLIENT_OLE2.ADD_ARG(objarg,0);
    objMail := CLIENT_OLE2.INVOKE_OBJ(objOutlook,'CreateItem', objarg);
    CLIENT_OLE2.DESTROY_ARGLIST(objarg);
    objAttach := CLIENT_OLE2.GET_OBJ_PROPERTY(objmail, 'Attachments');
    objarg := CLIENT_OLE2.CREATE_ARGLIST;
    CLIENT_OLE2.ADD_ARG(objarg,'c:\temp\test.txt'); -- filename
    CLIENT_OLE2.SET_PROPERTY(objmail,'To','[email protected]');
    CLIENT_OLE2.SET_PROPERTY(objmail,'Subject','Email sent from Oracle Forms 9i');
    CLIENT_OLE2.SET_PROPERTY(objmail,'Body','This is an email that was sent using
    CLIENT_OLE2 from Oracle forms 9i');
    CLIENT_OLE2.INVOKE(objattach, 'Add', objarg);
    CLIENT_OLE2.INVOKE(objmail,'Send');
    CLIENT_OLE2.RELEASE_OBJ(objmail);
    CLIENT_OLE2.RELEASE_OBJ(nameSpace);
    CLIENT_OLE2.RELEASE_OBJ(objOutlook);
    CLIENT_OLE2.DESTROY_ARGLIST(objarg);
    END;
    Notes:
    These are just 2 different ways of sending a mail by Outlook and using the
    Outlook Object Model.
    The first example can also be used with CLIENT_OLE2, and the second example can
    also be used with OLE2.
    (just replace every OLE2 to CLIENT_OLE2 or every CLIENT_OLE2 call to OLE2).

  • Use of FREE Command

    Hi,
    Can anybody answer pros and cons of using FREE Command?
    Regards
    Nilesh

    Serdar's post is correct, though I would like to add a clarification if I may.
    Say you have an internal table ITAB with a record length of around 1K, holding around 1,000 rows.  If we look at memory allocation simply, we can say that this internal table ITAB occupies about 1MB of memory.
    If you use the statement <b>REFRESH ITAB</b> then afterwards the internal table ITAB will be empty, but the internal table will not release the 1MB of memory previously allocated.  This can have a performance advantage if your just going to fill the internal table up again, as it re-uses this memory.
    If you use the statement <b>FREE ITAB</b> then afterwards, the internal table will be empty but the allocated memory will also be released.  Thus if you subsequently repopulate the internal table, the work process will have to reallocate memory again.  Using FREE can be particularly important in long-running, high volume processes, when an internal table is no longer required.
    FREE originated as a command to manage internal tables.  It has subsequently be extended to explicitly destroy class instances in ABAP Objects (as well as OLE2 automation references via FREE OBJECT ...).
    Using <b>FREE objref</b> is the same as using <b>CLEAR objref</b>.  That is, the variable objref will no longer hold a reference to the class instance.  Whether the object is actually destroyed by the garbage collector depends on whether other references to the instance are still held.
    Cheers,
    Scott
    Message was edited by Scott Barden following clarification by Klaus.

  • ALSM_EXCEL_TO_INTERNAL_TABLE , ERROR SY-SUBRC = 2 , UPLOAD_OLE

    Hi,
    I would like to know in what cases sy-subrc is '2' in function ALSM_EXCEL_TO_INTERNAL_TABLE
    the result of this function depends the version of excel, office ???
    Somebody can help me ?

    Hi Michael,
    It is a Upload error from Excel file.
    The return value of sy-subrc is as follows in Help.SAP.com
    Return Value
    SY-SUBRC
    Return value set by the following ABAP statements. In general, a content of 0 means that the statement was executed without problems.
    ·        ASSIGN sets SY-SUBRC to 0 if assignment to field symbol is possible, otherwise 4.
    ·        ASSIGN <dref>->* sets SY-SUBRC to 0 if dereferencing is possible, otherwise 4.
    ·        AUTHORITY-CHECK sets SY-SUBRC to 0 if the user has the necessary authorization, otherwise 4, 8, 12, 16, 24, 28, 32, or 36 depending on the cause.
    ·        CALL DIALOG with USING sets SY-SUBRC to 0, if processing was successful, otherwise <>0.
    ·        CALL FUNCTION sets SY-SUBRC according to the exception handling.
    ·        CALL METHOD sets SY-SUBRC according to the exception handling.
    ·        CALL SELECTION-SCREEN sets SY-SUBRC to 0 if the user chose Enter or Execute and 4 if the user chose Cancel.
    ·        CALL TRANSACTION with USING sets SY-SUBRC to 0 if processing was successful, otherwise <>0.
    ·        CATCH SYSTEM-EXCEPTIONS sets SY-SUBRC if there are runtime errors after the ENDCATCH statement. The value is specified in the program.
    ·        COMMIT WORK sets SY-SUBRC to 0.
    ·        COMMIT WORK AND WAIT sets SY-SUBRC to 0 if update was successful, otherwise <>0.
    ·        COMMUNICATION INIT DESTINATION u2026 RETURNCODE sets SY-SUBRC as specified.
    ·        CONCATENATE sets SY-SUBRC to 0 if the result fits into target variable, otherwise 4.
    ·        CREATE OBJECT sets SY-SUBRC if the exceptions of the instance constructor are handled.
    ·        CREATE OBJECT in OLE2 sets SY-SUBRC to 0 if an external object was created, otherwise 1,2, 3 with different causes.
    ·        DELETE sets SY-SUBRC to 0 if the operation was successful, otherwise 4 or <> 0 depending on cause.
    ·        DEMAND u2026 MESSAGES INTO sets SY-SUBRC to 0 if a message table is empty, otherwise <> 0.
    ·        DESCRIBE LIST sets SY-SUBRC to 0 if row or list exists, otherwise 4 or 8.
    ·        EXEC SQL - ENDEXEC sets SY-SUBRC to 0 in almost all cases. Only if no set was read with FETCH is SY-SUBRC 4.
    ·        FETCH sets SY-SUBRC to 0 if at least one row was read, otherwise 4.
    ·         GENERATE SUBROUTINE POOL sets SY-SUBRC to 0 if generation was successful, otherwise 8.
    ·        GET CURSOR sets SY-SUBRC to 0 if the cursor is correctly positioned, otherwise 4.
    ·        GET PARAMETER sets SY-SUBRC to 0 if value found in SAP Memory, otherwise 4.
    ·        IMPORT sets SY-SUBRC to 0 if import of data objects was successful, otherwise 4.
    ·        LOAD REPORT sets SY-SUBRC to 0 if the operation was successful, otherwise 4 or 8 depending on cause.
    ·        LOOP sets SY-SUBRC to 0 if loop over extract was passed at least once, otherwise 4.
    ·        LOOP AT sets SY-SUBRC to 0 if loop over internal table was passed at least once, otherwise 4.
    ·        MODIFY sets SY-SUBRC to 0 if operation was successful, otherwise 4.
    ·        MODIFY LINE sets SY-SUBRC to 0 if list row was changed, otherwise <> 0.
    ·        MODIFY sets SY-SUBRC to 0 if operation was successful, otherwise 4.
    ·        OLE2 automation, bundled commands set SY-SUBRC to 0 if all were successfully executed, otherwise 1, 2, 3, 4 depending on cause.
    ·        OPEN DATASET sets SY-SUBRC to 0 if the file was opened, otherwise 8.
    ·        Open SQL commands set SY-SUBRC to 0 if operation was successful, otherwise <>0.
    ·        OVERLAY sets SY-SUBRC to 0 if at least one character is overlayed, otherwise 4.
    ·        READ DATASET sets SY-SUBRC to 0 if the read operation was successful, otherwise 4 or 8 depending on cause.
    ·        READ LINE sets SY-SUBRC to 0 if list row exists, otherwise <> 0.
    ·        READ TABLE sets SY-SUBRC to 0 if the table row was found, otherwise 2, 4, 8 depending on cause.
    ·        REPLACE sets SY-SUBRC to 0 if search string could be replaced, otherwise <> 0.
    ·        ROLLBACK WORK always sets SY-SUBRC to 0.
    ·        SCROLL sets SY-SUBRC to 0 if scrolling in list successful, otherwise 4 or 8 depending on cause.
    ·        SEARCH sets SY-SUBRC to 0 if search string was found, otherwise 4.
    ·        SELECT sets SY-SUBRC to 0 if at least one row was read, otherwise 4 or even 8 with SELECT SINGLE FOR UPDATE.
    ·        SET COUNTRY sets SY-SUBRC to 0 if country ID was found in table T005X, otherwise 4.
    ·        SET BIT sets SY-SUBRC to 0 if bit was set, otherwise <> 0.
    ·        SET TITLEBAR sets SY-SUBRC to 0 if title exists, otherwise 4.
    ·        SHIFT u2026 UP TO sets SY-SUBRC to 0 if position was found in character string, otherwise 4.
    ·        SPLIT sets SY-SUBRC to 0 if size of target fields is sufficient, otherwise 4.
    ·        UPDATE sets SY-SUBRC to 0 if operation successful, otherwise 4.
    ·        WRITE u2026 TO sets SY-SUBRC to 0 if assignment successful, otherwise 4.
    Thanks & Regards,
    Dileep .C

  • OLE2 Word automation problem

    I am trying to find out how to right align (justify) text being selected into a word document.
    application : = Word.basic;
    ole2.invoke(application,"insert command here");
    i cannot for the life of me find out the command to insert in the invoke statement that word will not just ignore.
    please help!
    email me at [email protected] if you can help me
    null

    Ok, you'll want to move the service to a Farm Administrator account (doesn't have to be the farm admin, but an account with Farm Admin rights). This account should have a Full Control policy over the Web Application. In addition, add the Application Pool
    account of the Web Application(s) to the WAS database:
    $db = Get-SPDatabase | where {$_.TypeName -eq "Microsoft.Office.Word.Server.Service.QueueDatabase"}
    $db.GrantOwnerAccessToDatabaseAccount("domain\username")
    $db.Update()
    Trevor Seward
    Follow or contact me at...
    &nbsp&nbsp
    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

Maybe you are looking for

  • No network, WiFi, 3G after iOS 7.0.6 Update (iPhone 4s)

    Following my update to iOS 7.0.6 which completed with no apparent problems, my phone has lost all connectivity to my network, WiFi and 3G services. 'Carrier Settings' no longer appears in my Settings menu, and in 'About' I cannot view IC, or IMEI num

  • After upgrade: Error code: ssl_error_ssl_disabled in Firefox 3.6.10 Mac OS 10.6.4 - no mozilla-based "solution" works!

    In Firefox settings: SSL 3.0 is used, no proxy, network.dns.disableIPv6 set to true. The Mac OS firewall has been tested as turned off/on, but still no secure website (e.g. gmail) can be loaded. This happened first after the upgrade to 3.6.6. I then

  • Recording from Mixer to Muvo 200 mi

    Hi ! i ?m thinking buying a muvo 200 micro so that i can record my dj sessions directly to the muvo 200 micro. I just want to know if the quality is ok and if the process of recording from the mixer to Muvo 200 micro is automatically converted in mp3

  • Parsing xml using DOM parser in java

    hi there!!! i don have much idea about parsing xml.. i have an xml file which consists of details regarding indentation and spacing standards of C lang.. i need to read the file using DOM parser in java n store each of the attributes n elements in so

  • What is being done to this image?

    Can anyone give me some basic pointers to make the image on the left side look more like the image on the right side? I tried adjusting the White Balance with the eyedropper in the Levels by selecting the white on her shirt, I also played with the Le