cancel
Showing results for 
Search instead for 
Did you mean: 

Retrieving the data from BAPI passing default SAP user name

Former Member
0 Kudos

Hi,

I have requirement like this,

I should should retrieve expense reports details by passing default SAP user name to

the BAPI.

I have done the following steps,

Step :1

I created "LoggedInUser" attribute in both view and component controller and I mapped them.

Step :2

In my first view,

I have hard code the user name,

wdContext.currentContextElement().setLoggedInUser("IDADMIN");

Step 3:

And in my component controller, I have binded the value to the BAPI field,

Sap_Wapi_Count_Workitems_Input input = new Sap_Wapi_Count_Workitems_Input();

wdContext.nodeCount().bind(input);

String names = wdContext.currentContextElement().getLoggedInUser();

input.setUser(names);.

I have checked whether the BAPI field is retrieving the value by giving message.

Yes user name is bind to BAPI.

But in my second view, the data is not retrieving for expense reports for that user name.

Please guide me with the procedure to retrieve the expense reports details by passing the

user name.

Regards,

Anitha.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

thanks

Former Member
0 Kudos

Hi,

you put external breakpoint in bapi and check whether the username is passing to that bapi or not.

Regards,

Sunaina Reddy T

Former Member
0 Kudos

Hi ,

Thanks for ur immediate reply.

Can i knoe=w how to put external break point in BAPI

Regards,

Anitha.

Former Member
0 Kudos

Hi,

Open function module using "se37" tcode.

In that function module u find one red color button called "set/delete" button.

one dialog box will display in that u select "HttpSession breakpoint".

Regards,

Sunaina Reddy T

Former Member
0 Kudos

Hi,

I put the external break point, I think so its not calling BAPI of that user.

Please guide me with some sugeestion to retrieve the data by passing the user name.

Thanks,

Anitha

Former Member
0 Kudos

Hi anitha,

Is that bapi triggred or not ?

Regards,

Sunaina