Problem in passing data from 1 screen to another using BBP_DOC_CHANGE_BADI.

Hi Experts,
i am new to the SRM, i am facing problem in passing data from one screen to another.
my requirement is that when we select one shopping cart and press the PROPOSE SOURCES OF SUPPLY button, we will fetch all the contracts that are attached to the shopping cart.
we have implemented a BADI implementation of BBP_SOS_BADI (method BBP_SOS_CHECK) for passing some changed values to the contracts of the shopping cart into the popup screen that is displayed when we press PROPOSE SOURCES OF SUPPLY button and when we select any contract and press ASSIGN ONLY button in the popup screen the badi BBP_DOC_CHANGE_BADI is triggered.
i have implemented another BADI implementation of BBP_DOC_CHANGE_BADI for fetching the selected contract and pass the values to another screen, but the problem is that when we select one contract and press the assign only button we are fetching the wrong contract number ( that is in the BADI method BB_SC_CHANGE parameter IT_ITEM we are fetching the wrong contract), if we again do the same procedure for the second time we are getting the correct contract.
i am unable to understand why we are getting the wrong contract in the first time( that is we are getting contract other than the selected one).
as per my understanding i think when we are passing data to the popup screen using BBP_DOC_CHANGE_BADI we are not updating the shopping cart with the changed data.
can anyone tell me how we can update the SHOPPING CART with the changed contracts data, i have used BBP_PD_SC_UPDATE, BBP_PD_SC_SAVE and other shopping cart FM but nothing is happening.
Thanks
Tanveer

Hello,
What version of SRM are you on?  Have you check for OSS Notes?  I have had trouble with BBP_DOC_CHANGE_BADI but it was because of other issues.  The BADI works pretty well and it is called almost every time something happens to the shopping cart.
I have noticed that sometimes that values are not changed til the second calling of the BADI.  I have yet understand why but I think it has to do with prompt processing. Usually, we train our requisitioners to click the 'Check'  button to flush things out.
I don't know if I was helpful.... another thought.... could there be an error caught by BBP_DOC_CHECK_BADI that is preventing change in BBP_DOC_CHANGE_BADI?
Regards, Dean.

Similar Messages

  • Pass data from servlet to jsp using sendRedirect

    Hi,
    I am passing data from servlet to jsp using forward method of request dispatcher but as it doesn't change the url it is creating problems. When ever user refreshes the screen(browser refresh) it's re-loading both servlet and jsp, which i don't want to happen. I want only the jsp to be reloaded.
    Can I pass data from servlet to jsp using sendRedirect in this case. I also want to pass some values from servlet to jsp but without using query string. I want to set some attributes and send to jsp just like we do for forward method of request dispatcher.
    Is there any way i can send data using attributes(without using query string) using sendRedirect? Please let me know

    sendRedirect is meant as a true redirect. meaning
    you can use it to redirect to urls not in your
    context....with forward you couldn't pass information
    to jsps/servlets outside your own context.Actually, you can:
    getServletContext().getContext("/other").getRequestDispatcher("/path/to/servlet").forward(request, response)I think the issue here is that the OP would like to have RequestDispatcher.forward() also update the address in the client's browser. That's not possible, AFAIK. By the time the request is forwarded, the browser has already determined the URL of the servlet, and the only I know of way to have the browser change the URL to the forwarded Servlet/JSP is to send a Location: header (i.e. sendRedirect()). Remember that server-side dispatching is transparent to the client. Maybe there's some tricky stuff you can do with JavaScript to change the address in the address bar without reloading the page?
    Brian

  • Problem in passing data from one .jsp page to another .jsp page

    i have a problem here
    Actually i have 2 jsp pages. What im trying to do here is actually i want to pass data from the first jsp page to the second for updating
    The first jsp page contains data that user wants to update in the form of table.
    <td><img src = "edit.gif" alt = "edit" border="0" ><td>
    <TD><%= Name %></td>
    <TD><%= rs.getInt("Age") %></td>
    <TD><%= rs.getString("Gender") %></td>
    So this page displays the data that users wants to update plus one image button (edit button). So when user clicks this button, all the data in this page will be brought to the second .jsp page called updatePersonal for updating.
    The problem here is that it is not displaying the existing data in the second .jsp page.
    The second page basically contains forms
    <INPUT TYPE="text" NAME="FirstName" maxlength="30" value = "<%=FirstName%>">
    Can someone please help me. I really dont know what to do..How do i get the data displayed in the text field that is passed from the first .jsp page..thankx in advance

    Please modify below code to:
    td><img src = "edit.gif" alt = "edit" border="0" ><td>
    -----------------modified code
    td><a href="updatePersonal.jsp?FirstName=<%=rs.getString(FirstName")%">&LastName=<%=rs.getString("LastName")%>&Age=<%=rs.getInt("Age")%>&Gender=<%=rs.getString("Gender")%>"><img src = "edit.gif" alt = "edit" border="0" ></a><td>
    I'm sure it works</a>

  • Problem with reading data from screen and inserting in table

    hi ther,
    im new to abap-webdyn pro. can anyone suggest how to read data from screen and insert into table when press 'ADD' button.
    i done screen gui , table creation but problems with action. what the content of acton add.
    is ther any link that helps me or tut??
    thankx in advance!
    regards

    Hi,
    Create a context node for the screen fields for which you want to enter the values with cardinality 1.1.....
    Now in the layout of your view bind the screen input fields to that context node(attributes) to the value property of the input fields...
    Now in the action of ADD button....
    --> go the wizard and select the read node button and select the node which you have created it generates the auto code for you.....
    for example if the node is contains aone attribute like MATNR
    reading the node from wizard will generate the code as....
    DATA lo_nd_matnr TYPE REF TO if_wd_context_node.
      DATA lo_el_matnr TYPE REF TO if_wd_context_element.
      DATA ls_matnr TYPE wd_this->element_matnr.
      DATA lv_matnr TYPE wd_this->element_matnr-matnr.
    * navigate from <CONTEXT> to <MATNR> via lead selection
      lo_nd_matnr = wd_context->get_child_node( name = wd_this->wdctx_matnr ).
    * @TODO handle non existant child
    * IF lo_nd_matnr IS INITIAL.
    * ENDIF.
    * get element via lead selection
      lo_el_matnr = lo_nd_matnr->get_element( ).
    * @TODO handle not set lead selection
      IF lo_el_matnr IS INITIAL.
      ENDIF.
    * get single attribute
      lo_el_matnr->get_attribute(
        EXPORTING
          name =  `MATNR`
        IMPORTING
          value = lv_matnr ).
    here the variable lv_matnr will contain the entered value......
    now you can use this value for further process.
    Thanks,
    Shailaja Ainala.

  • Passing data from one screen to another(web-dynpro) in SRM sourcing cockpit

    HI Experts,
    i am facing problem in passing data from one web-dynpro screen and assigning the data it to another web-dynpro screen.
    my requirement is that when ever user selects a contract in PROPOSE SOURCES OF SUPPLY screen popup and press only assign only button, the data of the contract should be copied to the shopping cart.
    i have already used the BADI BBP_DOC_CHANGE_BADI, but unfortunately it was not working.
    so i tried to use the context, element and other web-dynpro fields to pass the data, i am able to pass the data from the popup to the second screen and able to assign it.
    but when ever i deselect the shoppping cart which has been assigned with the data of the popup and select another shopping cart the data of the above shopping cart is cgetting changed.
    i am unable to figure out the exact reason why this is happeing.i have written code in the ASSIGN ONLY button method to fetch the popup data and in the WDONMODIFYVIEW method of the second screen to assign the popup data to the shopping cart.
    i have tried to bind the elements using the BIND_TABLE, BIND_STRUCTURE, BIND_ELEMENT, BIND_ELEMENTS methods, but nothing is working.
    can anyone suggest me where i am making mistake and try to solve the issue.
    Thanks
    Tanveer

    Dear Poster
    Your thread has had no response since it's creation over
    2 weeks ago, therefore, I recommend that you either:
    - Rephrase the question.
    - Provide additional Information to prompt a response.
    - Close the thread if the answer is already known.
    Thank you for your compliance in this regard.
    Jason Boggans
    SAP SRM SDN Moderator

  • Passing data from one frame to another frame

    hello all, i am having a problem with passing data from one frame from another. I have a main frame when you click on connect button it display the second frame(class) that has 2 text fields and 2 buttons. When i click on connect it check if the data is correct. If the data is correct i want that frame to close and pass the data back to main frame. How can i do that.
    thank you

    hello all, i am having a problem with passing data
    from one frame from another. I have a main frame when
    you click on connect button it display the second
    frame(class) that has 2 text fields and 2 buttons.
    When i click on connect it check if the data is
    correct. If the data is correct i want that frame to
    close and pass the data back to main frame. How can
    i do that.
    thank you
    the original problem sounded like an ideal opportunity to use Modal Dialog. if you want one frame to display another to get user input then you need to stop the method in the main frame from executing until you recieve a valid input.
    you can use your own class and keep all of the components that you have in the connect frame but you would have to extend JDialog instead of JFrame.
    there is a way around it!
    if you must use JFrame for both, then you need to have access to the main frame in the connect frame, maybe pass the pointer to the constructor??
    anyway, when the connect frame is done with its duties, you have to use the pointer to call another method in the main frame that will continue the process. otherwise main frame doesn't know when connect frame is done and by that time, the method in main frame that instantiated the connect frame has long since died.
    also, it allows things to happen in the other window that you may not want to happen until the connect frame is done
    typically users of software start clicking around on things and you could have three or four connect frames going at the same time
    it's really best to use a Modal Dialog, it really can look just like a JFrame!!!!!!!!!!!!!!

  • How to pass data from smartform to user exits in appl form print workbench

    Dear All,
    I am using print workbench + smartforms to develop a form.
    But facing problem with passing data from the smartform back to
    the user exits includes in the application form of the print workbench.
    For eg:- Supppose the case , passing the total number of pages 'sfsy-formapages'  to the application form .
    I tried with the export interface of the smartform, still it doesn't works!
    Any suggestions/solutions
    Thanks
    santhv

    Hi Prashanti,
    Thank you very much...
    Using EXPORT/IMPORT , I am able to pass the data.
    But I would like to know whether it is  the final solution.
    As there is export interface is available for smartform....
    why it is not possible to get back the data in Application form.
    Please confirm, so that I can close the post.
    Anyway thank you once again....
    Regards,
    santhv

  • Error passing data from ODS to IC

    Hi,
    I have a problem when passing data from ODS to Infocube. According to the messages, the problem is there is erroneous characters in one record's ZANLAGE characteristic. I check and found the problematic record. Mi question is Why the problem showed up when passing data from ODS to IC instead of when passing data from Infosource to ODS? I check de ODS and the problematic record is in: "       " (hex.). How this characteristic value entered in the ODS correctly, but it can not enter the IC??
    Mauricio

    Hi,
    I check the ODS settings and the BEx option is not checked. This may explain whay the problem showed up passig from ODS to IC and not before.
    What should I do to catch the problem and pass the data from the ODS to the IC?
    My problem is how to identify this record, can I use:
    if ZANLAGE = "       "
      ZANLAGE = "XXXXXX".
    end if.
    Remember that "       " is Hex. code!!.
    regards
    Mauricio

  • How to pass data from one internal session to another internal session

    hi all sap experts ,
    How to pass data from one internal session to another internal session and from oneExternal session to another external session.
    Except : Import and Export parameters and SPA/GPA parameters.
    Tell me the otherWay to pass data ..
    Plz
    Thanks in advance

    hi,
      abap memory management u will understand about this concept.
    the import /export parameter will help u that passing data between two internal sessions by using abap memory.
      for syntax
    Passing Data Between Programs
    There are two ways of passing data to a called program:
    Passing Data Using Internal Memory Areas
    There are two cross-program memory areas to which ABAP programs have access (refer to the diagram in Memory Structures of an ABAP Program) that you can use to pass data between programs.
    SAP Memory
    SAP memory is a memory area to which all main sessions within a SAPgui have access. You can use SAP memory either to pass data from one program to another within a session, or to pass data from one session to another. Application programs that use SAP memory must do so using SPA/GPA parameters (also known as SET/GET parameters). These parameters can be set either for a particular user or for a particular program using the SET PARAMETER statement. Other ABAP programs can then retrieve the set parameters using the GET PARAMETER statement. The most frequent use of SPA/GPA parameters is to fill input fields on screens (see below).
    ABAP Memory
    ABAP memory is a memory area that all ABAP programs within the same internal session can access using the EXPORT and IMPORT statements. Data within this area remains intact during a whole sequence of program calls. To pass data to a program which you are calling, the data needs to be placed in ABAP memory before the call is made. The internal session of the called program then replaces that of the calling program. The program called can then read from the ABAP memory. If control is then returned to the program which made the initial call, the same process operates in reverse. For further information, refer to Data Clusters in ABAP Memory.
    Filling Input Fields on an Initial Screen
    Most programs that you call from other programs have their own initial screen that the user must fill with values. For an executable program, this is normally the selection screen. The SUBMIT statement has a series of additions that you can use to fill the input fields of the called program:
    Filling the Selection Screen of a Called Program
    You cannot fill the input fields of a screen using additions in the calling statement. Instead, you can use SPA/GPA parameters. For further information, refer to Filling an Initial Screen Using SPA/GPA Parameters.
    Message was edited by:
            sunil kumar
    Message was edited by:
            sunil kumar

  • How can I pass data from a form guide to another form in a business process

    How do we pass data from a form guide to another form(not necessarily a guide) without having to open the form. For example we have a small form guide to capture the contract id so we can then get data from contracts table to present to the user in a form. We want the user to open the guide (either Flex guide or form guide) to enter the contract id. Upon submission we want the process to get the contract data and put it into the form that will be opened at the next step by the user without having a user interact with the form to get the data into it. In other words we need the process to get the data and populate a different form than the form guide the contract id was entered in and this new form needs to be opened in the next step by the user.

    Firstly, I'm assuming that you have a Forms ES Server if you are rendering a Guide.  This could be either version ES1, ES2/2.5 or ES3/ADEP
    If you submit the form back to the server, you can populate a second (PDF/XDP) form with the data bound to the same schema/Data Model using Forms ES. 
    You referred to the next user in the chain - If you are using Process Management, this is very easy, as you define what form is used to render the data in the "Presentation & Data" section of the Assign Task activity

  • Passing data from a container to another

    Hi,
    Let's say I have two containers (Container1=application , Container2).  Container1 gets some data from user, perform some database lookup and displays Container2 with the results from database lookup.
    Container1 --(call and display)--> Container2
    Below shows  how I am using a bindable variable in Container1 to pass the data from Container1 to Container2.  Also shows how I display Container2 from Container1.
    <!-- Container1 -->
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
       [Bindable] public var foo:String = "bar";
       private function loginHandler(event:LoginEvent):void
          mycontainer2 = new Container2();
          mycontainer2.name = "mycontainer2";
          this.addChild(mycontainer2);
    </mx:Application>
    I am accessing the data in Container2 as follow:
    <!-- Container2 -->
    {mx.core.Application.application.foo}
    Q1) Is there a better way to pass data from one container to another and access the data?
    Q2) Is this the only way to call and display Container2 from Container1?
    Q3) How can I move back to Container1 from Container2, i.e. Container2 call and display Container1
           Container2 --(back to)--> Container1

    Best practices call for using custom events to share data between components. Here is my Flex 3 Cookbook post on the topic:
    http://cookbooks.adobe.com/index.cfm?event=showdetails&postId=15466
    To switch easily between containers 1 & 2 use a ViewStack, the gold standard for such interaction, and manipulate the selectedIndex or selectedChild property:
    http://livedocs.adobe.com/flex/3/html/help.html?content=navigators_3.html
    If this post answered your question or helped, please mark it as such.

  • Passing data from one bsp application to another

    Hi,
    I have few queries that most of you would have done in ur projects:
    1. I want to pass data from one bsp application to another:
    eg based upon selected row of table view which populates material no and descriprion to another application which open the entire material master data.
    Now, i have both the pages in diff bsp applications in place but unable to pass the selected material code to the second bsp application.
    Had it been two different pages of same application I was able to achieve it with set parameter()
    2. To stop the application from reprcessing the data:
    eg: Suppose I have a bsp page where user fill details of a customer and on submitinng the details a customer is created in background and the entire page is disabled by my code. Even now if the user press refresh (F5) button then another customer gets created in the background. So basically i want to avoid the reprocess of the onSubmit event
    Few lines of sample code would be very helpful.
    Best Regards,
    Saurabh Tripathi

    Hi,
    When I am writing the following code in appl1/page1:
            export abc from transactionID
            to data buffer lv_page_data.
            CALL METHOD CL_BSP_SERVER_SIDE_COOKIE=>SET_SERVER_COOKIE
              EXPORTING
                NAME                  = 'TRANSACTIONID'
                APPLICATION_NAME      = RUNTIME->application_name
                APPLICATION_NAMESPACE = RUNTIME->application_namespace
                USERNAME              = ls_name
                SESSION_ID            = runtime->session_id
                DATA_VALUE            = lv_page_data
                DATA_NAME             = 'lv_page_data'
    and following code in appl2/page2:
      CALL METHOD CL_BSP_SERVER_SIDE_COOKIE=>GET_SERVER_COOKIE
        EXPORTING
          NAME                  = 'TRANSACTIONID'
          APPLICATION_NAME      = RUNTIME->application_name
          APPLICATION_NAMESPACE = RUNTIME->application_namespace
          USERNAME              = ls_name
          SESSION_ID            = runtime->session_id
          DATA_NAME             = 'lv_page_data'
        CHANGING
          DATA_VALUE            = lv_page_data
       IF lv_page_data IS NOT INITIAL.
         IMPORT abc to transactionid
           FROM data buffer lv_page_data.
       ENDIF.
    still the code doesn't work. Please explain and guide
    Best Regards,
    Saurabh Tripathi

  • What are Parameters? How are they differenet from Variables? Why can't we use variables for passing data from one sequnece to another? What is the advantage of using Parameters instead of Variables?

    Hi All,
    I am new to TestStand. Still in the process of learning it.
    What are Parameters? How are they differenet from Variables? Why can't we use variables for passing data from one sequnece to another? What is the advantage of using Parameters instead of Variables?
    Thanks in advance,
    LaVIEWan
    Solved!
    Go to Solution.

    Hi,
    Using the Parameters is the correct method to pass data into and out of a sub sequence. You assign your data to be passed into or out of a Sequence when you are in the Edit Sequence Call dialog and in the Sequence Parameter list.
    Regards
    Ray Farmer

  • Best practice - Pass data from Custom Comp to Another Custom Comp

    Hi, id like to know what would be the best practice to pass data from a custom component to another custom component. Right now I got these options:
    1st Component Custom Event - Main App - Public Properties 2nd Component
    1st Component Custom Event - Main App - Public Setter 2nd Component
    Is there another more directly way of doing it? or a better way?
    Thanks

    Hi, id like to know what would be the best practice to pass data from a custom component to another custom component. Right now I got these options:
    1st Component Custom Event - Main App - Public Properties 2nd Component
    1st Component Custom Event - Main App - Public Setter 2nd Component
    Is there another more directly way of doing it? or a better way?
    Thanks

  • How to pass data from one internal session to another

    Hi SAP Experts,
    How to pass data from one internal session to another and from One external session to another external session. I used import and export parmeter and SPA/GPA parameters. What is the other way to pass data?
    Please tel me urgently
    Thank you
    Basu

    Memory Structures of an ABAP Program
    In the Overview of the R/3 Basis System you have seen that each user can open up to six R/3 windows in a single SAPgui session. Each of these windows corresponds to a session on the application server with its own area of shared memory.
    The first application program that you start in a session opens an internal session within the main session. The internal session has a memory area that contains the ABAP program and its associated data. When the program calls external routines (methods, subroutines or function modules) their main program and working data are also loaded into the memory area of the internal session.
    Only one internal session is ever active. If the active application program calls a further application program, the system opens another internal session. Here, there are two possible cases: If the second program does not return control to the calling program when it has finished running, the called program replaces the calling program in the internal session. The contents of the memory of the calling program are deleted. If the second program does return control to the calling program when it has finished running, the session of the called program is not deleted. Instead, it becomes inactive, and its memory contents are placed on a stack.
    The memory area of each session contains an area called ABAP memory. ABAP memory is available to all internal sessions. ABAP programs can use the EXPORT and IMPORT statements to access it. Data within this area remains intact during a whole sequence of program calls. To pass data to a program which you are calling, the data needs to be placed in ABAP memory before the call is made. The internal session of the called program then replaces that of the calling program. The program called can then read from the ABAP memory. If control is then returned to the program which made the initial call, the same process operates in reverse.
    All ABAP programs can also access the SAP memory. This is a memory area to which all sessions within a SAPgui have access. You can use SAP memory either to pass data from one program to another within a session, or to pass data from one session to another. Application programs that use SAP memory must do so using SPA/GPA parameters (also known as SET/GET parameters). These parameters are often used to preassign values to input fields. You can set them individually for users, or globally according to the flow of an application program. SAP memory is the only connection between the different sessions within a SAPgui.
    The following diagram shows how an application program accesses the different areas within shared memory:
    In the diagram, an ABAP program is active in the second internal session of the first main session. It can access the memory of its own internal session, ABAP memory and SAP memory. The program in the first internal session has called the program which is currently active, and its own data is currently inactive on the stack. If the program currently active calls another program but will itself carry on once that program has finished running, the new program will be activated in a third internal session.
    Data Clusters in ABAP Memory
    You can store data clusters in ABAP memory. ABAP memory is a memory area within the internal session (roll area) of an ABAP program and any other program called from it using CALL TRANSACTION or SUBMIT.
    ABAP memory is independent of the ABAP program or program module from which it was generated. In other words, an object saved in ABAP memory can be read from any other ABAP program in the same call chain. ABAP memory is not the same as the cross-transaction global SAP memory. For further information, refer to Passing Data Between Programs.
    This allows you to pass data from one module to another over several levels of the program hierarchy. For example, you can pass data
    From an executable program (report) to another executable program called using SUBMIT.
    From a transaction to an executable program (report).
    Between dialog modules.
    From a program to a function module.
    and so on.
    The contents of the memory are released when you leave the transaction.
    To save data objects in ABAP memory, use the statement EXPORT TO MEMORY.
    Saving Data Objects in Memory
    To read data objects from memory, use the statement IMPORT FROM MEMORY.
    Reading Data Objects from Memory
    To delete data clusters from memory, use the statement FREE MEMORY.
    Deleting Data Clusters from Memory
    please read this which provide more idea about memory
    Message was edited by:
            sunil kumar

Maybe you are looking for

  • Cannot open Terminal at all!

    All new in the Mac World, and I don't know if it's something I'm doing wrong or what? The only thing that happens when I click on the app is that the screen flickers, like a window is opened but it isn't. Could anyone help me? I have a Macbook pro

  • Replace the XML Tags which are in binary format in 4.6C Version

    Hi Experts, I have an issue. I am working on 4.6 c version of sap. I have a requirement to send  ftp of an xml file. I created an internal table which has components of table type too ( For Line items ). After appending a record of sales order into t

  • 10.1.0.4 to 11gR2 (11.2.0.2.0)

    Hi there, We are going to upgrade our database from 10g to 11g and we are planning on using the export/import method. Will the fact that we are on 10.1.0.4 as oppose to 10.1.0.5 make any difference seeing as we are using the export/import method? As

  • How to detrimine date duration, minus weekend days and days on hold

    I need to determine duration of a request by when the request went from Milestone_ 3 to Milestone_8 (but if Milestone_8 is null use Milestone_7) minus weekend minutes. But I also need to find the days when a request was On Hold and subtract those day

  • Change cell colors used within a function

    While using various functions in a spreadsheet I use to track my bills on a monthly basis, the functions do a great job of highlighting all the cells included. The problem is.....I cannot see them well, some not at all, since I am color blind and the