cancel
Showing results for 
Search instead for 
Did you mean: 

Using the variable "Parameter" type in a BSP page

Former Member
0 Kudos

I have my code working to the point where I can call the BAPI -->BAPI_SERVNOT_GET_DETAIL and not have the program crash. Now what is happening is that when I pass it a value, I am not getting any data returned. I have traced through the program and there is a check that compare the value I entered with what is in the database. At this point I am getting a NOT FOUND error. I then run the BAPI in SE37 and it work fine with data returned when I enter the same value.

Most of the ABAP code for this BSP is coming from a Z-Transaction that our developer created, where the attribute P_QMUM is defined as:


PARAMETERS: P_QMNUM LIKE RIWO00-QMNUM OBLIGATORY
     MEMORY ID IQM
     matchcode object QMEG.

I have tried to enter the above code into my BAP, but get an error that 'PARAMETER' can not be defined in either the form or event handler.

1: do I really need to use the above declaration for P_QMNUM?

2: If so, then how do I enter it?

Thanks again for all the help

Also, I have been searching for any notes to cover this topic with no luck. Is there some trick that I can use to narrow the search so that I can get closer to a solution and not have to keep on asking quesiton of this group?

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hello,

with


PARAMETERS: P_QMNUM LIKE RIWO00-QMNUM OBLIGATORY

you define an ui element. This works only in a Selection screen or Dynpro. IN BSP you can not use this statement!

Former Member
0 Kudos

Thanks

Then I guess I do not understand why my BSP is not working with this BAPI. Must be something else I am missing

Edited by: John Esposito on Mar 26, 2010 2:25 PM

Former Member
0 Kudos

can you please post your code?

Former Member
0 Kudos

Hi John,

In normal ABAP Report / Executable program if we need to get some details from user, we use parameters or select-options. But in BSP we cannot use these, instead we have to make use of UI elements.

But in BSP, the scenario would be

You will have 2 pages, one for selection screen and other for result.

1. First page will have UI elements like input fields and Button for submit. onInputProcessing must be triggered on click on button, and set the value entered in input field to the second page attribute.

2. In the result page, onInitialization even handler read the value from first page and call the BAPI with that value and display the results in Layout.

Hope you are clear now

Regards,

Ravi

Former Member
0 Kudos

Thank you again for your help. Have a good week

Answers (0)