I have the following working process in place at the moment.
Witihin my context node class I have a SET_COUNTRY method which detects whether the country code has been changed and if it has sest an attribute named 'country_flag'.
Withinin my controller class I have a method called do_prepare_output which detects if this 'country_flag' is set and then based on the value for the country populates a few other Z fields, then resets the flag.
This works fine and should I update the Account screen and change the Country code then code works fine, but ONLY if I hit (RETURN) key.
My aim was to simulate this processing so that the code gets performed once a value from the drop-down is assigned the country field.
In my context node class I have a P_ getter method like so:
method GET_P_COUNTRY. case iv_property. when if_bsp_wd_model_setter_getter=>fp_server_event. rv_value = 'submit'. endcase.
In my controller class I have the following code against the do_handle_event:
method DO_HANDLE_EVENT. CASE htmlb_event_ex->event_server_name. WHEN 'submit'. eh_onsubmitonenter( htmlb_event = htmlb_event htmlb_event_ex = htmlb_event_ex ).
I was under the illusion that this should be sufficient to trigger a server roundtrip and looks very similar to the recommended code shown in the How-to Guide:Dropdown Boxes.
I also believe that the event eh_onsubmitonenter can be empty and the above should be sufficient to trigger a server round trip.
Where I think the problem lies is in the method GET_P_COUNTRY. If I place a break point I can see that the iv_property field never equals 'server_event' and so rv_value is never set to 'submit'. However, even if I manually change the content the round-trip is still not triggered.
What actually triggers GET_P_COUNTRY to be called with a value for server_event, and what do you believe I need to put in place so that the processing code is called when the drop-down value is chosen?.
Jason