Can't i use OLE in webdynpro?

Hello
Pls. let me know is the OLE will not work in a custome WebDynPro application? Because, in debugging it went well, but no MS Word document has been created on my local desktop!!
When i run it as test STAND ALONE report program, it worked well.
When i copied & pasted the same code into my web dynpro appluication, its not creating any MS Word documents on my desktop!!
Actually, i can create the MS Word by using CLASSES also, but, i need the below piece
  CALL METHOD OF zword 'EDITREPLACE'
    EXPORTING
    #01 = 'FIND_TEXT'
    #02 = ls_partner1-name_org1
    #03 = 0
    #04 = 0
    #05 = 0
    #06 = 0
    #07 = 0
    #08 = 0
    #09 = 0
    #10 = 1
    #11 = 0
    #12 = 1.
Thank you

Thank you. got it.
As i mentioned i can create the MS Word on my desktop from webdynpro by using the below code,
  WDR_TASK=>CLIENT_WINDOW->CLIENT->ATTACH_FILE_TO_RESPONSE(
    I_FILENAME   = 'WDP.doc'
    I_CONTENT     =  ls_upload-doc_content
    I_MIME_TYPE = 'WORD' ).
But, my main requirement is to FIND & REPLACE some of the text on this MS Word doc., i am achieving this requirtement with the below code, pls. let me know How can achive the same in webdynpro?
  CALL METHOD OF zword 'EDITREPLACE'
    EXPORTING
    #01 = 'FIND_TEXT'
    #02 = ls_partner1-name_org1
    #03 = 0
    #04 = 0
    #05 = 0
    #06 = 0
    #07 = 0
    #08 = 0
    #09 = 0
    #10 = 1
    #11 = 0
    #12 = 1.
Thank you

Similar Messages

  • Can I use OLE in WebDynpro 4 Abap??

    I got a complicate request that need to read from an EXCEL template and edit the EXCEL.
    the Excel file can only be a normal .XLS file with macro in it,so XML don't work here.
    I try to use an OLE object to operate the excel in WD Application but an error happened when create the OLE object.     while there's no problem to create it in a normal Report program.
    is there any way to use OLE in WD Application???  otherwise i should write program to read the binary file of excel myself....

    looks to me that you need to use the UI element for office integration, standard available in wd4 abap.

  • Can I use OLE DB to acces thir party hierachical database Applix / TM1 ?

    Hi,
    I have got an Applix / TM1 Boi.
    Form the Applix / TM1 box I need to get some data in my Oracle Data Warehouse.
    Applix / TM1 has got an OLE DB Interface.
    Can I access this OLE DB Interface from my Oracle Database in Batch ?
    Is this possible ?
    How ?
    Thank You for Your Advice
    Martin Sautter

    Thanks for that...but can I do multiple edits in my Stored Procedure Vaibhav and pass back something that I can then utilize in my SSIS? For example...
    One and Only one Member Span...so I'd be doing a SELECT COUNT(*) based on my match criteria or handle the count accordingly in my Stored Procedure and passing something back via the OLE DB Command and handling it appropriately in SSIS
    Are there "Diabetes" claims...again probably by analyzing a SELECT COUNT(*)
    Am I expecting too much from the SSIS...should I be doing all of this in a Stored Procedure? I was hoping to use the SSIS GUI for everything but maybe that's just not possible. Rather use the Stored Procedure to analyze my stged data, edit accordingly, do
    data stores accordingly...especially the data anomalies...and then use the SSIS to control navigation
    Your thoughts........
    Could you maybe clarify the difference between an OLE DB Command on the Data Flow and the Execute SQL Task on the Control Flow...
    You can get return values from oledb comand if you want to pipeline.
    see this link for more details
    http://josef-richberg.squarespace.com/journal/2011/6/30/ssis-oledb-command-and-procedure-output-params.html
    The procedure should have an output parameter defined for that
    I belive if you've flexibility of using stored procedure you may be better off doing this in execute sql task in control flow. Calling sp in data flow will cause it to execute sp once for each row in dataset whereas in controlflow it will go for set based
    processing
    Please Mark This As Answer if it solved your issue
    Please Vote This As Helpful if it helps to solve your issue
    Visakh
    My Wiki User Page
    My MSDN Page
    My Personal Blog
    My Facebook Page

  • Can i Use Smartforms in Webdynpro? If so how ?

    Can i Use Smartforms in Webdynpro? If so how ? Sample Codes are Welcome..

    Hai Sai,
    U can convert the smart form into PDF format and use it.
    U can the check the below URL and understand it perfectly:
    <a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/f0de1eb8-0b98-2910-7996-8a3c2fcf6785">Smartform as pdf in webdynpro for abap</a>

  • Attention!!-don't use OLE object in Reports

    If you are planning to use or is currently using OLE objects in Reports-please don't use it as the object maynot reload in future and your report may not even open in Report Builder.I got this message when opening the report containing OLE object:
    REP-4004: Error occurred while restoring OLE object
    and it refused to open up crashing my days of work.
    The pity is I can't open my report even to remove the OLE object.

    I know that is weird.I placed the object in the same directory-but in vain.Afterall, what's the logic of putting it in the same directory after embedding it?

  • How to get TaskId's Information using UWL in Webdynpro?

    Hi,
      I've to get TaskId's Information using UWL in WebDynpro
      from SAP R/3 workflow.
      For e.g.  Name, Creation Date, Status etc.
    I'm able to see property Value in WebDynpro but instead of Property Value I want same Information in WebDynpro without using any Functional Module from R/3
    I'm giving the XML file structure which I'm using
    I want to display information about the task Id which I'm giving in this configuration.
    <?xml version="1.0" encoding="utf-8"?>
    <! DOCTYPE UWLConfiguration PUBLIC '-//SAP//UWL1.0//EN' 'uwl_configuration.dtd' [
      ]>
    <UWLConfiguration version="1.0">
      <ItemTypes>
        <ItemType name="uwl.task.webflow.TS91000129.UWL" connector="WebFlowConnector"
    defaultView="Test" executionMode="default" defaultAction="launchWebdynpro">
    <ItemTypeCriteria systemId="UWL" externalType="TS91000129" connector="WebFlowConnector"/>
    <Actions>
    <Action name="launchWebDynPro" handler="SAPWebDynproLauncher"
      returnToDetailViewAllowed="yes" launchInNewWindow="yes" launchNewWindowFeatures="width=800,height=600,resizable=yes,scrollbars=yes,status=yes,toolbar=no,menubar=no,location=no,directories=no">
      <Properties>
        <Property name="WebDynproApplication" value="TEST"/>
        <Property name="WebDynproDeployableObject" value="local/TEST1"/>
        <Property name="isnewwindow" value="1"/>
        <Property name="fruit" value="apple"/>
        <Property name="DynamicParameter" value="wi_id=${item.externaId}"/>
        <Property name="System" value="LocalSystem"/>
      </Properties>
    </Action>
    </Actions>
    </ItemType>
      </ItemTypes>
    </UWLConfiguration>
    Then in WebDynpro application I'm using this code
    String text = WDWebContextAdapter.getWebContextAdapter().getRequestParameter("DynamicParameter");
    If I give any other property name I'm able to get in WebDynpro application.
    But I tried it for Task Id using Dynamic Parameter I was getting a Blank Value.
    Please Help Me.

    Hi Niharika,
    I think you have a typo in your code. You can retrieve the work item id by using [code]<Property name="DynamicParameter" value="wi_id=${item.<b>externalId</b>}" />[/code] instead of [code]<Property name="DynamicParameter" value="wi_id=${item.<b>externaId</b>}"/>[/code]
    In addition, you can get values from the work item container by extracting them as custom attributes:
    [code]<ItemType name="uwl.task.webflow.TS90000001.<system id>" connector="WebFlowConnector" ...>
      <ItemTypeCriteria ... />
      <CustomAttributes>
      <CustomAttributeSource id="WEBFLOW_CONTAINER" objectIdHolder="<element name>" ...>
      <Attribute name="<element name>" type="string" displayName="<element description>" />
      </CustomAttributeSource>
      </CustomAttributes>
      <Actions>
        <Action name="launchWebDynPro" handler="SAPWebDynproLauncher">
          <Properties>
            <Property name="DynamicParameter" value="<custom param>=${item.<element name>}" />
          </Properties>
          <Descriptions default="" />
        </Action>
      </Actions>
    </ItemType>[/code]
    Hope this helps,
    Mikko

  • To upload excel file directly to the application server using OLE concept

    hi experts
    i have done a coding in OLE to download excel with graph to presentation server, is it possible to upload excel with graph directly to the application server  , the excel should have graph while downloading to presentation server fom app server.
    Moderator message - duplicate post locked
    Edited by: Rob Burbank on Jun 25, 2009 9:49 AM

    HI,
    have a look at tcode cg3z and then FM 'C13Z_FILE_UPLOAD_ASCII'.
    What you can do is, first create the file on presentation server using OLE automation, and then using this FM, write the file to Application server

  • ALV download to Excel onto desktop using OLE concept.

    Hi Experts,
    I requriement is , through my se38 program i need to download report output to excel.
    i did this using OLE concepts code and excel is being downloaded good.
    But problem is all columns data is dumped into First column. But in my ALV i have 20 columns. So i except data in excel sheet to be in 20 columns.
    Below is the OLE code i used
    CREATE OBJECT wa_excel 'EXCEL.APPLICATION'. "Create object for Excel
      SET PROPERTY OF wa_excel  'VISIBLE' = 1. "In background Mode
      CALL METHOD OF wa_excel 'WORKBOOKS' = w_workbook.
      CALL METHOD OF w_workbook 'ADD'. "Create a new Workbook
      SET PROPERTY OF wa_excel 'SheetsInNewWorkbook' = 3. "No of sheets
    * Downloading header details to first sheet
      PERFORM download_sheet TABLES i_final USING 1 'Master Material Details'.
      GET PROPERTY OF wa_excel 'ActiveSheet' = w_worksheet.
    * Protect the first worksheet with a password
      CALL METHOD OF w_worksheet 'PROTECT
        EXPORTING #1 = 'infy@123'.
    * Save the Excel file
      GET PROPERTY OF wa_excel 'ActiveWorkbook' = w_workbook.
      CALL METHOD OF w_workbook 'SAVEAS'
        EXPORTING #1 = p_infile.
      FREE OBJECT: w_worksheet, wa_excel.
    FORM download_sheet TABLES p_tab  USING p_sheet TYPE i   p_name  TYPE string.
      CALL METHOD OF wa_excel 'WORKSHEETS' = w_worksheet
        EXPORTING
        #1 = p_sheet.
      CALL METHOD OF w_worksheet 'ACTIVATE'.
      SET PROPERTY OF w_worksheet 'NAME' = p_name.
      CALL METHOD OF wa_excel 'Range' = w_range
        EXPORTING
        #1 = 'A1'
        #2 = 'D1'.
      CALL METHOD OF w_range 'INTERIOR' = w_int.
      SET PROPERTY OF w_int 'ColorIndex' = 6.
      SET PROPERTY OF w_int 'Pattern' = 1.
    * Initially unlock all the columns( by default all the columns are locked )
      CALL METHOD OF wa_excel 'Columns' = w_columns.
      SET PROPERTY OF w_columns 'Locked' = 0.
    * Locking and formatting first column
      CALL METHOD OF wa_excel 'Columns' = w_columns
       EXPORTING
       #1 = 1.
    * Locking and formatting second column
      CALL METHOD OF wa_excel 'Columns' = w_columns
        EXPORTING
        #2 = 2.
      SET PROPERTY OF w_columns  'Locked' = 2.
      SET PROPERTY OF w_columns  'NumberFormat' = '@'.
    * Export the contents in the internal table to the clipboard
      CALL METHOD cl_gui_frontend_services=>clipboard_export
        IMPORTING
          data                 = p_tab[]
        CHANGING
          rc                   = w_rc
        EXCEPTIONS
          cntl_error           = 1
          error_no_gui         = 2
          not_supported_by_gui = 3
          OTHERS               = 4.
    * Paste the contents in the clipboard to the worksheet
      CALL METHOD OF w_worksheet 'Paste'.
    * Autofit the columns according to the contents
      CALL METHOD OF wa_excel 'Columns' = w_columns.
      CALL METHOD OF w_columns 'AutoFit'.
      FREE OBJECT: w_columns, w_range.
    Please help me if there is any SET Property of WA_EXCEL with which i can handle ALV data into Diffrenet columns.
    Regards,
    jayant.

    hi nabheet,
    we have implemnted this logic and it is workign fine. Bit it takes long time to download data in Excel sheet. Actually it is happening feild by field.
    Please advice any perfomance tuning to this logic.
    Rgs,
    jayant

  • How to use messages in WebDynpro-ABAP

    Hi,
        How to use messages in WebDynpro-ABAP.
    Does it has any class to manage messages like IWDMessageManager or we can just use standard SAP Message types.. like E,W,X,I,S..
    I hope it have a message container to display messages.
    Thank U for Ur time.
    Cheers,
    Sam

    Hi Sam,
    U can hard code the message or u can use the Assistance class's text elements to store the messages.
    1) Code to display hard coded message:
    report message
    CALL METHOD l_message_manager->report_attribute_error_message
    EXPORTING
    message_text = "Enter the correct Connection ID"
    element = elem_flightinfo
    attribute_name = 'CONNID'.
    2) Code to display message from text element of assistance class:
    lv_text = wd_assist->if_wd_component_assistance~get_text( key = '002' ).
    report message
    CALL METHOD l_message_manager->report_attribute_error_message
    EXPORTING
    message_text = lv_text
    element = elem_flightinfo
    attribute_name = 'CONNID'.
    Where Message "Enter the Correct Connection ID" is stored in Text Element with key '002'
    Hope this helps,

  • Message Mapping in HRAS - can it be used for ESS ?

    We came across this functionality for EHP2 (after activating business function HCM_ASR_CI_1)
    called "message mapping" while implementing HCM processes and forms framework. It is available under HR Administrative services -->Tools in the IMG provided the business function is activated. 
    As per IMG documentation for this Message Mapping node --> "The tool for mapping messages can also be used in Employee Self-Services and applications of the Enterprise Service-Oriented Architecture"
    Just wanted to check if anyone tried exploring this by mapping messages for ESS services outside of HCM Processes and forms framework? or Is this tool limited only for HCM P&F.

    I've seen the same thing. I suspect it "will" be possible but not fully implemented just yet. You could probably do a search on the mapping table and see if it is actully used in the newer ESS code at all. It looks like they have this in place as ESS transitions over more fully to Webdynpro ABAP and making use of the decoupled infotype framework.

  • Using OLE Objects in Forms 6i

    Hi
    I need to use OLE object (VSFlexGrid) in my forms 6i. can anybody help with some code by which I can achieve this.
    Warm Regards
    Vivek Bajaj

    Hi Shay,
    Thanks for the reply but i was unable to register to metalink. they need some support agreement code which i do not have. Can you please give me some more information on how to use that.
    waiting for an early reply.
    Warm Regards
    Vivek Bajaj

  • Connection to database using OLE DB provider??

    can anyone tell me how do we connect to a remote ms access database kept in a lan using OLE DB Provider.Please, show me the sample code also.

    This is what happened to me. I was getting the error: Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
    Specified driver could not be loaded due to system error 5. I then gave IUSR_machine name account and the IWAM_machine name accounts full access to the Bin folder.
    I then got the error: Microsoft OLE DB Provider for ODBC Drivers (0x80004005) Specified driver could not be loaded due to system error 998. I then gave IUSR_machine name account and the IWAM_machine name accounts full access to the whole Oracle home folder C:\Oracle\OraHome92, and it is working!!!!!
    Hope this helps.
    Thx,
    Scott Buerkley

  • Using OLE for download MS-Word

    Hello,
    can I use a MS-Word Template while creating an word obejct to write on the template
    I mean here-->
    CREATE OBJECT gs_word 'WORD.APPLICATION'.             "Create word object
    Thank you

    Hi,
    Chek out this wiki page:
    [Sample program to create a Word document from ABAP (using OLE) |http://wiki.sdn.sap.com/wiki/display/Snippets/SampleprogramtocreateaWorddocumentfromABAP%28usingOLE%29]
    Regards

  • Creating Excel Using OLE through ABAP

    Hi Experts,
    Can anyone help me in running an abap program to give an Excel file using OLE..
    Regards,
    Seshadri

    Hi Seshadri,
          Here is ur expected coding...
    REPORT ZCREATEEXCEL.
    TYPE-POOLS OLE2.
    DATA: EXCEL     TYPE OLE2_OBJECT,
          WORKBOOKS TYPE OLE2_OBJECT,
          WORKBOOK  TYPE OLE2_OBJECT.
    DATA: FILENAME LIKE RLGRAP-FILENAME.
    START THE EXCEL APPLICATION
      CREATE OBJECT EXCEL 'EXCEL.APPLICATION'.
      PERFORM ERR_HDL.
    PUT EXCEL IN FRONT
      SET PROPERTY OF EXCEL  'VISIBLE' = 1.
      PERFORM ERR_HDL.
    INFORM USER OF THE CURRENT STATUS
      CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
           EXPORTING
                PERCENTAGE = 0
                TEXT       = TEXT-I08
           EXCEPTIONS
                OTHERS     = 1.
    CREATE AN EXCEL WORKBOOK OBJECT
      CALL METHOD OF EXCEL 'WORKBOOKS' = WORKBOOKS.
      PERFORM ERR_HDL.
      CALL METHOD OF WORKBOOKS 'ADD' = WORKBOOK.
      PERFORM ERR_HDL.
    EXCEL FILENAME
      CONCATENATE SY-REPID '_' SY-DATUM6(2) '_' SY-DATUM4(2) '_'
                  SY-DATUM(4) '_' SY-UZEIT '.XLS' INTO FILENAME.
      CALL METHOD OF WORKBOOK 'SAVEAS' EXPORTING #1 = FILENAME.
      FORM ERR_HDL.
      IF SY-SUBRC <> 0.
        WRITE: / 'OLE ERROR: RETURN CODE ='(I10), SY-SUBRC.
        STOP.
      ENDIF.
    ENDFORM.
    hope it helps..

  • Use EJBs in Webdynpro

    Dear All,
    We have the following scenareio to be achieved,
    Use Database of the WAS Java engine and table creation using NWDS. - this can be done using data dictionary
    Use EJBs Data Updation - we have created a EJB project. One ear project which can be deployed to j2ee engine.
    In webdynpro we can able to create a java bean model. But when try execute this applicaiton, it leads to null pointer exception.
    Any idea what could be the reason for this.
    Thanks,

    Thanks for your immediate reply.
    Sharing reference: sap.com/QuickCarRentalEar.
    Finished with warnings: development component 'Frames'/'local'/'LOKAL'/'0.2008.06.12.18.12.16'/'0':Caught exception during application startup from SAP J2EE Engine's deploy service:java.rmi.RemoteException: Error occurred while starting application local/Frames and wait. Reason: Clusterwide exception: server ID 13390350:com.sap.engine.services.deploy.container.DeploymentException: Clusterwide exception: Failed to prepare application ''local/Frames'' for startup. Reason=Clusterwide exception: Failed to start application ''local/Frames'': The referenced application ''sap.com/QucikCarRentalEar' can''t be started. Check the causing exception for details. Hint: Is the referenced application deployed correctly on the server?
    Any inputs?...
    Can any one throw some lights on internally how this webdynpro calls ejb and process completes.
    Thanks..

Maybe you are looking for