• Duc Anh Nguyen
    December 13, 2016 at 6:16 pm #3273

    Hi,

    I have a function in inline javascript. I would like to call it with in other function. Are there any way to do it?
    I have some pics describe about it.

    Regards,

    SPARK Support
    December 14, 2016 at 11:21 am #3276

    Hi Duc,

    Coach View Inline:

    this.getColor = function(){
    return “red”;
    }

    Text On Change Event:

    console.log(page.ui.get(“Content1”).getColor());

     

    Regards,

    Stephen P.

    Duc Anh Nguyen
    December 14, 2016 at 6:52 pm #3278

    Hi,
    Thanks for your support.
    I have two question.
    – If i write function in include javascript, can i do it like write function in inline script?
    – How to access control via include javascript.

    Regards,

    Duc Anh

    SPARK Support
    December 16, 2016 at 9:20 am #3310

    Hi Duc,

    Yes.  You may want to be careful about your naming conventions to ensure that you do not step on any functions in BPM or our controls.

    For those with the Enterprise version of our toolkit, we recommend following along with the article entitled Creating Your Own Control

    which demonstrates the techniques of how to add an AMD Dependency, call an function with arguments from the Inline JavaScript, add Web Files, pass Configuration Options, create scripts for Controls to include, handle Events and define methods that can be called from the inline JavaScript or the console.

    Regards,

    Stephen P.

    Duc Anh Nguyen
    December 20, 2016 at 6:53 pm #3330

    Hi,

    Thanks for your support. If i want create my own control, can i have more doc or example about it?

    Regards,

    Duc Anh

    jmac
    December 21, 2016 at 5:04 am #3332

    If you have not already done so, you might want to have a look at Section 4.1.1 Creating SPARK-compatible controls in this document.

    Regards

    JMAC

    Duc Anh Nguyen
    December 21, 2016 at 6:19 pm #3333

    Hi JMAC,

    Thanks for your response.

    Regards,

    Duc Anh

    SPARK Support
    December 23, 2016 at 8:51 am #3340

    Hi Duc,

    Glad that this helped.

    Regards,

    Stephen P.

Viewing 8 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic.

Start typing and press Enter to search