cancel
Showing results for 
Search instead for 
Did you mean: 

CRM 2007: exception using global controllers

0 Kudos

Hi all,

I'm trying to get the partners of an inbound call when creating a new order through Web GUI (CRM 2007).

I put this code inside the EH_ONNEW method of an class ZL_ICCMP_ER_ERPCARTVALUEV_IMPL (enhancement of

implementation class CL_ICCMP_ER_ERPCARTVALUEV_IMPL, of view ICCMP_ERP_ORDER/ERPCartValueView).


data: lr_cuco_partner TYPE REF TO CL_ICCMP_BT_CUCOPARTNER_IMPL.

      lr_cuco_partner ?= get_custom_controller( 'GLOBAL.ICCMP_BTPARTNER/CuCoPartner' ).

In the web gui after having confirmed a BP an inbound call is attached to the selected BP (section Customer Call is filled with data: partners, and so on).

But when I try to create a new order I get this exception:

An error occurred during event processing in view ERPCartValueView.htm

An exception has occurred Exception Class CX_BSP_WD_INCORRECT_IMPLEMENT - There is no node text 'BTAdminH' in controller 'ICCMP_BTPARTNER/BSPWDComponent'.

Method: CL_BSP_WD_CONTROLLER=>DO_CONTEXT_NODE_BINDING

Source Text Row: 39

What does this exception mean? How can I get partner table (or partner set) of bsp ICCMP_BTPARTNER?

Thank you in advance!

Cheers,

Luca

Accepted Solutions (0)

Answers (3)

Answers (3)

0 Kudos

Hi Luca!

I am facing the same problem. I cant get the custom controller neither, with almost the same error message. Did you find a solution to this? If yes, please post your answer.

Thanks

Tu

0 Kudos

Hello everybody and thanks for your reply! As I said, I used another way to get the data I needed, and now everything goes smooth. However:

@Vinay

No, you cannot access the custom controllers of other bsp components..

I think your right about the scope and lifecycle of the controllers, yet you can get some controllers (global ones) and I was even able to get a custom controller as a global one (even if it's not defined in the interface I posted above).

@Pankaj

I thought so too, but sometimes some errors happens...

@Nguyen

What's your problem? Maybe there are some tricks to get it out.

Cheers!

Luca

0 Kudos

Hi Luca!

My problem is that after calling the

 
    cuco ?= me->get_custom_controller( 'GLOBAL.ICCMP_BTPARTNER/CuCoPartner' )."#EC NOTEXT

the cuco variable will remain initial, and i get the same error message as u wrote in the beginning of this topic.

Thanks

Tu

0 Kudos

Hi Nguyen,

I mean what's the issue you have to resolve... I guessed the problem was the same as mine...

Maybe you can use another global controller. Please, have a look to IF_ICCMP_GLOBAL_CONTROLLER_CON interface attributes, and try using a controller that sound like your needs. Maybe BPIDENT, but actually it depends on what you have to do.

Cheers,

Luca

Former Member
0 Kudos

Hi Lulani,

I am trying to change the partners in the runtime, for that i got the BOL reference of BTAdminH, from that i also got BTPartnerSet reference. Can you please tell me how to add or remove the partner.

Thanks,

Karthik

Former Member
0 Kudos

hi,

as per my understanding at the time of setting value in attribute of your custom controller of other component, if you specify global.custom controller in get custom controller, you will be able to access through other component.

Best Regards

PAnkaj Kumar

Former Member
0 Kudos

Hey Luca,

Can you put a break poing at line 39 in the method

CL_BSP_WD_CONTROLLER=>DO_CONTEXT_NODE_BINDING and send the call stack ? BY this way we can find out where exactly in the application component the error occured.

If you want to access the partner set/details in ur view, you can access it by getting the related entities of your root object. The BOL Model should already provide this ..

Regards,

Vinay

0 Kudos

Hello Vinay,

first of all, thanks for your answer. I bypassed my problem getting the BTOrder root object and then the partners.

So my question, now, is why can't I get that custom controller. Can I only get global controllers? Are all the global controller defined in the if_iccmp_global_controller_con interface? Can't I get custom controller defined in other bsp?

Former Member
0 Kudos

No, you cannot access the custom controllers of other bsp components..

The reason is .. the view controller instance is available only till the page is in focus.. more over the idea of controller is to call the context related methods to get the data from the underlying APIs and send them to HTM page.. nothng but the MVC architecture..

I guess there should be some customizing in SPRO where we can find the global controllers ..

Let me take a look at the system and update u on that front..

Hope this info helps you

Thanks,

Vinay