Call_controller & goto_page

I guess these are basically the two ways to ´navigate´ around my application..
1)we can use call_controller() to call a subcontroller and show it inside the current view. or we would show only the subcontroller view if the parent controller doesn´t have a page(view) of its own.
2)in case we just want to call another page, giving it full controll, that is our current controller will die as soon as the new one is invoked. in this case we can use goto_page(). I´m missing only one thing here.. how to pass parameters.. a string for example.. Can we use navigation->get/set_parameter()?
I also found the useful application object. We have a reference to this instance from every controller..! Even from a controller that we called using goto_page().
I´m planning to use this ´application´ object to share objects references between different controllers. This is my idea: finding a way to pass parameters to a controller that I called using goto_page() then using that parameter to the the reference of an object instance that I´m keeping in the application class (just the way controllers keep a list of model objects using a string as key to get their reference)
I would greatly appreciate any comments on this..

Craig,
This is great, now we have TWO very good choices to  handle navigation and therefore structure our applications.
Our goal now should be to find the pros and cons of each. I whish someone with this kind of experience would read this post and share his/her experience!!
a)we can have a controller with different views (I´d use this for controllers that switch between view/edit mode).
b)calling subcontrollers is obviously necessary to build pages 'composed' by several controllers/views. For example a search tray and a result-display tray. Or a list-elements tray and a display-selected-element tray.
c)The most powerfull reason that I found to use goto_page is that in a big application you just can´t have a main controller handling all the rest. I mean I just wouldn´t know how to do it..? When and from where to create/call/destroy subcontrollers..? (does anyone have an answer for this?)
Anyway.. the use of goto_page allows you to have a low coupling.. (at least that´s the way I see it..)
Using this alternative you can structure your application in ´modules´ and make a goto_page to swith from clients to projects just to give an example..
d)One last question that I have. what should be kept in the application class, how should it be kept and for how long? who is responsible to destroy objects that are no longer used? Remember that we could have a controller create a model, register that model in the application class, then call another controller with goto_page, passing the model´s name as parameter. this other controller would look up the model by its name (that we passed as url parameter) and use it. We could also have global data.
any comments are welcomed!!!

Similar Messages

  • Call_controller

    How can I specify target(frame) in call_controller.
    I have a sub controller which I would like to launch from DO_HANDLE_EVENT of my MAIN controller but would like to load the view in a particular frame.
    How can I do this?
    Please help.
    Thanks,
    Partho

    I know, this is an old Thread, but it is exactly the Problem, which I have at the Moment.
    What I have is 3 controllers with 1 view each controller. 1 controller is the maincontroller and in the view is the frameset. In the frameset are the other 2 controllers. Ok till now no Problem.
    But when I now have a button, lets call it leftframe, and when I click on it, I want that there is coming up a Tableview in the rightframe.
    I know how to set up a button and get the event, but not how I get the controller to call in do_handle_event to call the controller of the view which should be shown up in the rightframe.
    Any Clues?
    Thanks Benjamin

  • How to use ' NAVIGATION- GOTO_PAGE' goto a new page

    Hello friends.
    when I use a hyperlink.
    I can open a new page by set target="_blank" or target="_parent" etc.
    How can do the same thing by using
    NAVIGATION->GOTO_PAGE(mypage.htm)
    in OnInputProcessing.
    Thank You.

    Hi Meiok,
    have a look at thread Navigation in BSP, this might give you some ideas for the solution.
    Regards,
    Rainer

  • Navigation- GOTO_PAGE and ANCHOR

    Is it possible to add a anchor destionation to have an equivalent of <a href="destination.htm#myanchor"> but with Navigation Method GOTO_PAGE ?

    If your message is answered please remember to mark it that way that others in the future can find "solutions" faster. There's a little yellow star next to the mesage that answered your problem.
    For more info you can see this :O Rules of Engagement --- 2005-02-25 from Brian.

  • Open a new window with navigation- goto_page?

    Hello,
    i am trying to display informations by opening a bsp-page in a new window.I know how to to it with javascript "window.open".My problem is that i am using the phtmlb_menubar and i think i must do it by oninputprocessing with navigation->goto_page.
    I tried the navigation->USE_AUTO_SUBMIT_FORM with a new target.This works,but in this case i can't do anything in the "old-window". How can i navigate to a new page in a new-window without loosing the control in the "old-window"?
    Thanks for answers.

    Uuups,
    i didn't recognized that phtmlb_popummenuitem has a LINKTARGET attribute. That should work now.
    10 Reward-Points for you;-)
    Thanks.
    Message was edited by: Frank Brackmann

  • Calling a subcontroller

    hi all,
    i have a problem regarding calling a subcontroller on pushbutton event. Actually i want to display a tableview in tray through this subcontroller.
    The content of tableview is coming according to my queries but the tray is not displaying.
    In runtime error i find that error is <htmlb:tray> Class <htmlb:event>(cl_htmlb_content) was not found as BSP parent elemnt.
    I am not able to figure out it completely as my scenario is very much similar to what has been given in ITMVC2 application.And there is not much
    difference in key things.
    Followings are code of view table.htm of my subcontroller table.do where i think problem lies.
    <%@page language="abap" %>
    <%@extension name="htmlb" prefix="htmlb" %>
       <htmlb:tray id="detail" title="Employee details" design="form" width="100%" isCollapsed="false">
            <htmlb:tableView id="tvX" width="100%" visibleRowCount="5" table="<%=model->emplist%>">
            </htmlb:tableView>
    </htmlb:tray>
    Thanks for any suggestion and help.
    Amit Kumar

    Hi Max,
    Below i am giving my codes.
    MAIN CONTROLLER
    DO_INIT
    method DO_INIT.
    data: model type ref to za_model_first.
    data: empdetails type ref to cl_bsp_controller2.
    create and register model object
    model ?= create_model( class_name = 'za_model_first'
                           model_id = 'mf' ).
    create subcontroller, but initially inactive
    empdetails ?= create_controller( controller_name = 'table.do'
                                        controller_id = 'fld' ).
    controller_set_active( controller_id = 'fld'
                           active = 0 ).
    empdetails->set_model( model_id = 'mf'
                              model_instance = model ).
    endmethod.
    DO_REQUEST
    method DO_REQUEST.
    data: page type ref to if_bsp_page.
    data: model type ref to za_model_first.
    data: subcontroller type ref to cl_bsp_controller2.
    dispatch_input( ).
    page = create_view( view_name = 'first.htm' ).
    model ?= get_model( 'mf' ).
    page->set_attribute( name = 'manager' value = model->manager ).
    page->set_attribute( name = 'show_tray' value = show_tray ).
    call method runtime->server->request->get_cookie
    exporting name = 'logname'
    importing value = logname.
    CALL METHOD page->SET_ATTRIBUTE
                EXPORTING
                       NAME = 'logname'
                       VALUE = logname.
    call method runtime->server->request->get_cookie
    exporting name = 'post'
    importing value = post.
    CALL METHOD page->SET_ATTRIBUTE
                EXPORTING
                       NAME = 'post'
                       VALUE = post.
    call_view( page ).
    if model->manager is not initial.
      subcontroller ?= get_controller( controller_id = 'fld' ).
      controller_set_active( controller_id = 'fld'
                             active = 1 ).
      call_controller( subcontroller ).
    else.
      controller_set_active( controller_id = 'fld'
                             active = 1 ).
    endif.
    DO_HANDLE_EVENT
    method DO_HANDLE_EVENT .
    DATA: table_event type ref to CL_HTMLB_EVENT,
      DATA: model type ref to za_model_first.
      DATA: event_id type string.
      data page type ref to if_bsp_page.
    event_id = event.
    if htmlb_event is not initial.
      event_id = htmlb_event->id.
    endif.
    data:fields type TIHTTPNVP,
      wa_fields like line of fields.
      CALL METHOD request->if_http_entity~get_form_fields
        CHANGING
          fields = fields.
      loop at fields into wa_fields where name = 'manager'.
        manager = wa_fields-value.
      endloop.
    case event_id.
    when 'go'.
                   model ?= get_model( 'mf' ).
                   if model is not initial.
                      show_tray = 'X'.
                      model->manager = manager.
                   endif.
    when 'cpwd'.
             navigation->goto_page( 'cpwd.do' ).
    endcase.
    sub controller:
    Only DO_REQUEST
    method DO_REQUEST.
    data: model type ref to za_model_first.
    data: view type ref to if_bsp_page.
    model ?= get_model( 'mf' ).
    if model is not initial.
    model->init( ).
      view = create_view( view_name = 'table.htm' ).
      view->set_attribute( name = 'model' value = model ).
      call_view( view ).
    endif.
    endmethod.

  • New page on click of absolute url

    I need IE to open new page of the absolute url when user click the url on initial page, but as result the new page always replace the inital page but not open a new session, I also refer to the threads in the forum like adding "sap-sessioncmd=open" or "syscmd=nocookie" but still does not work, can anyone give me any suggestion?following is my coding:
    Layout of the page1.htm:
    <htmlb:link id = "link1"
                text = "google with new session"
                reference = "http://www.google.com"
                target    = "_BLANK"
                onClick   = "LinkClick">
    <htmlb:link>
    OnInputProcessing:
      if event_id = cl_htmlb_manager=>event_id. " HTMLB event?
        data: lr_htmlb_event type ref to cl_htmlb_event.
        lr_htmlb_event = cl_htmlb_manager=>get_event( request ).
        if lr_htmlb_event is not initial.
          if lr_htmlb_event->server_event = 'LinkClick'.
            call method navigation->use_absolute_url.
            call method navigation->goto_page
              exporting
                url = 'http://www.google.com/ncr?sap-sessioncmd=open'
    *          url = 'http://www.google.com/ncr?sap-syscmd=nocookie'
                session = 'NEW'.
          endif.
        endif.
      endif.
    Message was edited by: Patrick Yan

    now i got a few minutes to work on this.
    here is a sample code.
    in the layout of the flow logic:
    i am using button for example,
    1) <htmlb:button id = 'CONTINUE'
          text          = "Continue"
          onClick       = "OnInputProcessing(continue)" />
    2) create a page attribute called index and also link the 'continue' page to the same page in the BSP
    3)in the layout
    <% IF INDEX = '1'.(use the dynamic link)
    l_url = 'http://www.google.com/'. %>
        <script type="text/javascript">
      <!--
        window.open("<%=l_url%>","ErrorLog","width=400,height=250,left=250,top=200 dependent=yes resizable=yes");
      //-->
    </script>
    4) in the oninput processing of this page
    assign event
      l_event = cl_htmlb_manager=>get_event( runtime->server->request ).
      IF l_event->id = 'CONTINUE'.
      l_index = '1'.
           navigation->set_parameter( name  = 'INDEX'
                                 value =  l_index ).
        navigation->NEXT_page( 'CONTINUE' ).
    endif.
    so when you click on the button you should get the google page in a popup.
    this is working for me. let me know if you are still having problms.
    regards,
    manasa

  • How to open a web page from a BSP ? Or swap from the actual URL to another?

    Hi,
    I have a BSP, executing some data loading. It works fine.
    I am trying to enhance it by adding a call to another URL, at the end of the program.
    The same code works when I execute it from transaction SE38. However, when this is executed from the BSP itself, the return code of the function CALL_BROWSER is 2.
    I made som debugs, and the CALL_BROWSER function executes another function which is WS_QUERY. And there, SAP seems not being able to find wich system it is running on.
    Has someone done that before?
    Here is the code of my BSP (the same that works in SE38):
    DATA : appname      TYPE string,
           ls_page_name TYPE string,
           cb_true      TYPE boolean,
           cb_false     TYPE boolean,
           url          TYPE string,
           c_url(2054)  TYPE c.
        MOVE : 'ZPC_STKVTES'     TO appname,
               'zpc_stkvtes.htm' TO ls_page_name,
               'X'               TO cb_true,
               '-'               TO cb_false.
        CALL FUNCTION 'UPWB_GET_APPLICATION_URL'
          EXPORTING
            application          = appname
            page                 = ls_page_name
            ib_additional_params = cb_true
            ib_in_subgui         = cb_false
            ic_preview_type      = 'B'
          IMPORTING
            url                  = url.
        CONCATENATE url '&bps-design_messages=X' INTO c_url.
        CALL FUNCTION 'CALL_BROWSER'
          EXPORTING
            url                    = c_url
            window_name            = ' '
            new_window             = 'X'
          EXCEPTIONS
            frontend_not_supported = 1
            frontend_error         = 2
            prog_not_found         = 3
            no_batch               = 4
            unspecified_error      = 5
            OTHERS                 = 6.
    Regards
    Laurent
    Message was edited by: Laurent THIBERT

    > Thanks, but can I use such technology within Abap?
    YES with report programs or dialog programs but not in BSP framework
    > I use the Event OnProcessing of the BSP to execute
    > many tasks, and then only I want to open or swap to
    > antoher URL.
    in that case you can either use
    navigation->goto_page(<url>) .
    or if you want to open the page in a new window.
    inoninputprocessing after all your processing done youc an set a varialbe say opennewwindow = 'YES'
    and in the layout write this code.
    <% if opennewwindow = 'YES' . %>
    <script>
          window.open( '<%= url %>', target='_balnk');
          </script>
    <% endif . %>
    Regards
    Raja

  • File Upload issue in MVC

    Hi,
    For my MVC application, I have created a main controller.
    On the DO_REQUEST of the main controller, I am setting the sub controllers, and directly calling that controller using create_controller, controller_set_active, and call_controller.
    I included dispatch_input( ) in the Main controller's DO_REQUEST method.
    Inside the DO_REQUEST  of the sub controller, I am creating a view using create_view and call_view methods.
    In this view, I have a <htmlb:tableView /> and a <htmlb:fileUpload />, with a button. The issue is that, when the button is clicked, in the DO_HANDLE_EVENT method of the sub-controller, I am not getting the File Data, or the table data.
    For File upload, I use the following -
    data lv_fupld_data TYPE REF TO cl_htmlb_fileupload.
    lv_fupld_data ?= cl_htmlb_manager=>get_data(
                          request = runtime->server->request
                          name    = 'fileupload'
                          id      = 'fupld_1').
    I have the <htmlb:form method       = "post"
                      encodingType = "multipart/form-data" > etc in the view.
    When I call this sub-controller directly from the browser (after including the dispatch_input( ) part in DO_REQUEST), I do not get any issue. I am able to read the file data and upload the file.
    Any Idea why this is happening?

    Hi Rakesh,
    I think I got your problem:
    You only have the htmlb:form in your view of the subcontroller, and not in the main view.
    Therefore the subcontroller works by itself, but not within the main controller.
    If you are including subcontrollers, then make sure the form element is only present in the view of the main controller, wrapping around any subcontroller calls. And don't use the form tag anymore in the subcontrollers.
    Just as you put dispatch_input() just in your top controller, also place htmlb:form only in your top view.
    Regards,
    Max

  • Save the image in SAP R/3 which is dispalyed in the portal.

    Hi all,
    I am have developed the picture upload using the BSP i am getting image displayed in the portal but with a check box. I would like to save this image in the SAP system with BP id .
    So could you please help me out to do it.
    here the code I have used.
        data: entity         type ref to if_http_entity,
              file           type xstring,
              content_type   type string,
          content_length        type string,
              num_multiparts type i,
              i              type i value 1,
              doEcho         type string,
              value          type string.
      find multipart containing file
        num_multiparts = request->num_multiparts( ).
        while i <= num_multiparts.
          entity = request->get_multipart( i ).
          value = entity->get_header_field( '~content_filename' ).
          if not value is initial.
          found a file!
            navigation->set_parameter( name  = 'content_filename'
                                       value = value ).
            content_type = entity->get_header_field( 'Content-Type' ).
            navigation->set_parameter( name  = 'content_type'
                value = content_type ).
          get file content
            file = entity->get_data( ).
          get file size
            content_length = xstrlen( file ).
            navigation->set_parameter( name  = 'content_length'
                value = content_length ).
          echo/download the same file again?
            doEcho = request->get_form_field( 'doEcho' ).
        if doEcho is not initial.
            set response data to be the file content
              runtime->server->response->set_data( file ).
            set the mime-type and file size in the response
              runtime->server->response->set_header_field(
                name  = 'Content-Type'
                value = content_type ).
              runtime->server->response->set_header_field(
                name  = 'Content-Length'
                value = content_length ).
              runtime->server->response->delete_header_field(
                name = 'Cache-Control' ).
              runtime->server->response->delete_header_field(
                name = 'Expires' ).
        endif.
            exit.
        endif.
          i = i + 1.
        endwhile.
        if doEcho is not initial.
          signal to the BSP runtime that the response data is
          complete and no onLayout method should be called to
          create the response
            navigation->response_complete( ).
        else.
          navigation->goto_page('Hs Munich dear3.JPG').
        endif.
    With best regards,
    Suneetha

    Khaled,
    Purchase Document Item Data Source fullfills the requirement of the PO activity, i mean PO created which has PO date and PO amount.
    Let me tell you my situation in detail:
    The requirement is like this:
    The report should contain all the procurement activities and report should display the three different scenarios of Procurement cycle:
    1) Only PO done
    2) Only PO and GR done.
    3) PO,GR and Invoice all done.
    and all scenario should be in one report i.e., if PO only done, then the  GR and Invoice should show blank and similarly for others.
    So I tried the following things in DEV.
    1) Custom DSO which gets loaded from 2LIS_02_ITM( for PO Information - PO date,PO Number , PO Amount) and 2LIS_02_SGR( for GR information - GR Number, GR date)
    2) 0LIV_DS01 (BI content) loaded from Invoice verifcation datasource 2LIV_06_INV.
    Then Created Infoset(Custom DSO Left Outer Join 0LIV_DS01 ) and then checked the report but it doesnt fullfill all the scenario's of the Reporting as mentioned above..i.e., the report only shows the data only when Invoice done for the particular PO.
    So was trying to Build 3 Custom DSO's ( As similar to the SAP Business One Standard BI content DSO's  0SBO_O0,0SBO_O1,0SBO_O2) and then load it to the Cube and check whether it meets the requirement and so wanted to go for Generic Datasource..
    So, Can you please give your some valuable time to help me out in this situation and Correct me if have approached any long way ....and suggest to how to proceed?

  • How to Pass the internal table data?

    DearAll,
    How to pass the Data of one internal table on a 1.html page to another html page for output, in BSP Application.
    regards.

    Hi ,
    In the onInputProcessing event of the first page , write the following code...
    call method NAVIGATION->SET_PARAMETER exporting
        name = 'it_filt_cur'
        value = it_filt_cur.
    Here it_filt_cur is internal table.
              NAVIGATION->GOTO_PAGE('next.htm').
    In the next page , you can make the internal table as auto in the attributes.
    Since you have made the itab as auto transfer , you can directly access the itab in the initialization event of the next page if it is stateless.
    Regards,
    Laxman Nayak.
    Message was edited by: Laxman  Nayak

  • PDF download from BSP application

    hi all,
    With the bellow code i am able to download to PDF from BSP application
    Issue is when i click on the download button waiting popup window is not disappearing even after PDF displayed.
    Please help me to resolve how to stop this waiting popup window.
    response->delete_header_field( name = 'Cache-Control' ).  "#EC NOTEXT
      response->delete_header_field( name = 'Expires' ).        "#EC NOTEXT
      response->delete_header_field( name = 'Pragma' ).         "#EC NOTEXT
    Deactivated because of Note 904314 and Kompression in Kernel
      response->set_compression( options = '4' ).
      response->set_header_field( name  = 'content-type'
                                  value = 'application/pdf' ).
      response->set_header_field(
                         name  = 'cache-control'
                         value = 'max-age=0' ).
        response->set_header_field(
                           name  = 'content-disposition'
                           value = 'attachment; filename=candidate.pdf' ).
      l_pdf_len = XSTRLEN( l_pdf_xstring ).
      response->set_data( data   = l_pdf_xstring
                          length = l_pdf_len ).
      navigation->response_complete( ).
    Any help on this is highly appreciated.
    Thanks,
    Ravi

    May be you can navigate to another page AFTER the response_complete() method and show the message that 'PDF is downloaded successfully'
    or something meanful message. so that it will get a response back from server and 'wait...Processing' message might disappear.
    I'm not sure and didnt try..may be you can give it a try and let us know..
    navigation->response_complete( ).
    navigation->goto_page(....)

  • Accessing BSP File Download using HTTPS URL

    Hi,
    I'm struggling with a problem of downloading a file from a https url. I wrote a BSP App for downloading a file from a unix server.. It works fine when I use a http URL with port 8080 and does not work when I use https.!!
    Example:
    https://comms.gmsanet.co.za/supplier [ download does not work ]
    http://comms.gmsanet.co.za:8080/supplier [ download works ]
    When I try to download using https.. it does not pull the file name and path
    see code  below and suggest me if anything to be chnaged.
    In the Form Initialization method:
    event handler fr data retrieval
    DATA: i_file        type string,
          s_fields      TYPE tihttpnvp,
          s_fields_line TYPE ihttpnvp,
          multipart_form type ref to if_http_entity,
          file_upload    type xstring,
          lv_backend     type string,
          success        type string,
          entity         type ref to if_http_entity,
          file           type xstring,
          content_type   type string,
          content_filename type string,
          content_length type string,
          content_disposition type string,
          num_multiparts type i,
          i              type i value 1,
          doEcho         type string value 'X',
          value          type string,
          filename       type ZFILETAB-fileinfo,
          ext1           type string,
          ext2           type string,
          dsn            type string,
          bptype         like sy-uname,
          itab           TYPE ZFILETAB,
          itab_line      TYPE ZFILETABLINE,
          file_ext       type ZFILETABLINE,
          fileinfo       type c,
          zcount         type i.
        filename = '/NewMessge.doc'.
        content_filename = filename.
    Check the extension and assign the content type
        split filename at '.' into ext1 ext2.
        case ext2.
          when 'zip'.
            content_type = 'application/x-zip-compressed'.
          when 'doc'.
            content_type = 'application/msword'.
          when 'txt'.
            content_type = 'text/plain'.
          when 'ppt' or 'pps'.
            content_type = 'application/vnd.ms-powerpoint'.
          when 'xls' or 'exe'.
            content_type = 'application/octet-stream'.
          when 'gif'.
            content_type = 'image/gif'.
          when 'jpg' or 'jpeg'.
            content_type = 'image/pjpeg'.
          when 'htm' or 'html'.
            content_type = 'text/html'.
        endcase.
        dsn = filename.
        OPEN DATASET dsn FOR INPUT IN BINARY MODE.
        IF sy-subrc NE 0.
          zmessage = 'Error opening file'.
          navigation->set_parameter( name = 'zmessage' value = zmessage ).
          navigation->goto_page( 'downloaderror.htm' ).
          exit.
        ENDIF.
        DO.
          READ DATASET dsn INTO <b>file</b>.
          EXIT.
        ENDDO.
        CLOSE DATASET dsn.
    set response data to be the file content
      runtime->server->response->set_data( <b>file</b> ).
      runtime->server->response->set_header_field(
                                    name  = 'Content-Type'
                                    value = content_type ).
      concatenate 'attachment; filename=' filename into content_disposition.
      runtime->server->response->set_header_field(
                                    name = 'Content-Disposition'
                                    value = content_disposition ).
    set the file size in the response
      content_length = xstrlen( file ).
      runtime->server->response->set_header_field(
                                name  = 'Content-Length'
                                value = content_length ).
      runtime->server->response->delete_header_field(
                                name = 'Cache-Control' ).
      runtime->server->response->delete_header_field(
                                name = 'Expires' ).
      navigation->response_complete( ).
    Thanks
    Ajay

    Hi Brian,
    I have the same problem as Ajay Yeluguri. In http mode I can generate a download of an Excel document but when we use the portal in https it doesn't work.
    When I try to download using https it does not pull the file name and path and when I choose download I have a error message : "Internet Explorer cannot download from ..."
    I've test the point 3.2 "... including file up/download" of the BSP application IT00 and it works fine in http and https mode. My problem is not the upload but the download. And in this application the uploaded document is opened in the Internet Explorer window but I want to generate a Save as... window to download the file.
    Have you an idea what i can do to solve my problem.
    Thanks
    Yann

  • BSP File Download  - .TIF problems

    Dear all!
    I haven't been able to fix this problem,
    please see my post for further information. I am using SAP.help coding to display files in BSPs (6.20, "BSP with flow logic" pages used). See the coding below.
    Somehow .tif files can not be displayed. Every other mime type works fine.
    Thanks,
    Chris
    Dear all!
    In a quite complex file upload and download scenario which works fine we use the following coding to display files received from the backend in our page.
    OnInitialization: receives file backend data such as filesize, content(xstring) and mimetype.
    This works all fine. Mimetype is delivered correctly.
    OnInputProcessing:
    This has been taken from the help.sap.com documentation -
        runtime->server->response->set_data( mycontent ).
          runtime->server->response->set_header_field(
            name   = 'Content-Disposition'
            value = lv_downname ).
        runtime->server->response->set_header_field( name  = 'Content-Type' value = mymimetype ).
        runtime->server->response->set_header_field( name  = 'Content-Length' value = myfilesize ).
        runtime->server->response->delete_header_field( name = 'Cache-Control' ).
        runtime->server->response->delete_header_field( name = 'Expires' ).
        navigation->response_complete( ).
    RESULT:
    the file is displayed fine. When trying to save the displayed file locally on the hard disc, the mimetype is not available. The system (Windows XP) provides only .bmp as file type. Also the context menu entry "Properties" of the displayed file shows NOT AVAILABLE as mimetype.
    Is this a common problem? How can I achieve to have the mimetype information available for a save?
    Thankx,
    Christoph
    Message was edited by: Christoph Aschauer
    Message was edited by: Christoph Aschauer
    Message was edited by: Christoph Aschauer
    Message was edited by: Christoph Aschauer

    Hi,
    I am getting an error, when I try to download the document from the bsp-page.
    I have uploaded the document to the server-cache as mentioned above. If I test it on the standalone machine, everything works fine. But when I have to connect to the BSP-Application through an EP I am getting the error:
    BSP Exception: Das Objekt test.doc in der URL /sap(bD1kZSZjPTEwMCZwPTM1MjUwJnY9NiUyZTQmaT0xJnM9U0lEJTNhQU5PTiUzYWR0aXRtZXpfVE1FXzA3JTNhLUVVb2Y3MHRUN2JnMGFYMUNLeUVPakRRWmZBTTJVVE5aS21Lc0FRQi1BVFQ=)/bc/bsp/sap/zportal_rueckme/test.doc?sap-syscmd=nocookie ist nicht gültig.
    Test.doc is the name of the document I wish to download.
    Here comes the sample code.
      DATA: cached_response TYPE REF TO if_http_response.
      CREATE OBJECT cached_response
        TYPE
          CL_HTTP_RESPONSE
        EXPORTING
          add_c_msg        = 1.
      cached_response->set_data( l_document_x ). " l_document_x is a xstring
      cached_response->set_header_field( name  =   
                                        if_http_header_fields=>content_type
                                                              value = l_mime_type ).
      cached_response->set_status( code = 200 reason = 'OK' ).
      cached_response->server_cache_expire_rel( expires_rel = 180 ).
      CONCATENATE
                  RUNTIME->application_url
                  '/' l_file_name INTO e_url.
        cl_http_server=>server_cache_upload( url      = e_url
                                             response = cached_response ).
    Later I navigate to that URL:
            NAVIGATION->GOTO_PAGE( URL = e_url ).
    Any suggestions are appreaciated!
    Regards,
    Max

  • BOBJ Partner Training Catalog  login errors out  June 5, 2009 at 09:30 PT

    BusinessObjects Partner Training Catalog login page errors June 5, 2009 at 09:30 PT
    The URL https://partner.enablement.sap.com:/sap/bc/bsp/sap/z_lso_partner/login.htm was not called due to an error.
    Note
    ■The following error text was processed in the system WLP : Error when opening an RFC connection
    ■The error occurred on the application server pwdf1853_WLP_02 and in the work process 0 .
    ■The termination type was: RABAX_STATE
    ■The ABAP call stack was:
    Method: DO_HANDLE_EVENT of program Z_CL_BSP_LOGIN_CONTROLLER=====CP
    Method: DISPATCH_INPUT of program CL_BSP_CONTROLLER2============CP
    Method: DO_REQUEST of program Z_CL_BSP_LOGIN_CONTROLLER=====CP
    Method: DO_REQUEST of program CL_BSP_CTRL_ADAPTER===========CP
    Method: CALL_CONTROLLER of program CL_BSP_PAGE_BASE==============CP
    Method: IF_BSP_ELEMENT~DO_AT_END of program CL_BSP_CALL_ELEMENT===========CP
    Method: ONLAYOUT of program CLO2D4CAZHSXGQKTHE1ONREO61D6BCP
    Method: %_ONLAYOUT of program CL_O2D4CAZHSXGQKTHE1ONREO61D6BCP
    Method: DO_REQUEST of program CL_BSP_PAGE===================CP
    Method: ON_REQUEST of program CL_BSP_RUNTIME================CP

    Hello,
                    I am now experiencing the same problem as you have. Can you please tell how you managed to solve it. Thank you.

Maybe you are looking for

  • HT1178 time capsule set up with static ip

    Is set up of a time capsule the same with a static IP address as with a dynamic address? Is it still just plug it in and use airport utility to set up. We install a video survillance system to moniter an ill family member and the system installer say

  • Xml tag

    Hello, I'm on Java and I put a xml in a dom. Now I need to check that all "mytag" as a ddiferent "id" value: <xml........................>   <mttag id="one"............./>   <mttag id="two"............./>   <mttag id="one"............./> //--error  

  • How to integrate BW and Portal

    HI, Can any one guide me how to connect portal to BW system. I havent done it before. Do we have to do SSO and User mapping? can any one explain Step by Step procedure.? are there any prerequsites? Regards, Mag.

  • Is there a way to block access to programs?

    I want to block access to a program called Acquisition, as it's nothing more than a database for ***********. However, I can't seem to find any kind of program that will allow me to block and password protect access to the program. Does anyone know o

  • I'm needing help restoring an iPod touch 5 back to factory settings because I purchased it used

    I'm needing help in restoring an iPod touch 5th generation back to factory settings. Because I purchased it used from a family member who can not remember their password or sercuity question answers