CRM On Demand - Administration (MOSC)

MOSC Banner

Release 24 - JavaScript API - how to Create a Button to call a funtion in Client Side Extension

edited Nov 22, 2013 12:26AM in CRM On Demand - Administration (MOSC) 3 commentsAnswered ✓
Hello everybody,

I´m trying to use the new Release 24 JavaScript API to create a button to call a function in Client Side Extensions.  Does anyone have a sample of the code needed to call a Client Side Extension function from this button?  
I Know how to create the button, is something like that:

<script type="text/javascript">
oraclecrmod.onReady(function(){
            if(oraclecrmod.ctx.isObject("Campaign") && oraclecrmod.ctx.isDetailPage())
            {
                    var maTB = oraclecrmod.getTitleBar("CampaignTB");
                    // create the new button
                    button = oraclecrmod.createButton({id:"MyButton", text:"MyButton",parent:maTB});
                    // associate the myFunction with the button click event
                    button.on("click", myFunction);   
        }
});
</script>

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center