I have seen a few posts about this : how do I change a button label using a dynamic action? but I can not get it to work for me
We are using Apex 5.0 on Oracle 12
I have a select list {:PXX_VISITS) and when the user changes the value of the select list I want to change a button (:PXX_ADDVISIT) label so that it contains the value selected
The static id for the button is set to: (PXX_ADDVISITSTATICID)
I have a Javascript dynamic action that fires on change of the select list that contains the following (I have tried all of these individually but none works)
$("PXX_ADDVISITSTATICID").attr('value', 'DAMIFINO');
$("label[for=PXX_ADDVISITSTATICID]>span").html("DAMIFINO");
$("PXX_ADDVISITSTATICID").find(".t-Button-label").text('DAMIFINO');
$("#PXX_ADDVISITSTATICID").find(".span").text('DAMIFINO');
When I inspect the page I see the following for the button:
| <td align="left"><button value="Add New Visit" onclick="void(0);" class="button-default" type="button" id="PXX_ADDVISITSTATICID"> |
| <span>Add New Visit</span> |
I have put alerts in the DA so I know I am getting into the code, its just not changing the label or giving me any kind of error. So any ideas why none of the above options are working for changing the label?
TIA