Quantcast
Channel: Microsoft Dynamics CRM Forum - Recent Threads
Viewing all articles
Browse latest Browse all 87499

RE: Auto Populate Multi-line text field from tickbox selections

$
0
0

You could use something like this - bind the OnChange event of each field to this method:

function OnChange() {
    Xrm.Page.getAttribute("new_multi").setValue(null);
    var message = "";

    if (Xrm.Page.getAttribute("new_field1").getValue()) {
        message = "text1";
    }

    if (Xrm.Page.getAttribute("new_field2").getValue()) {
        if (message != null) {
            message += "\r\n";
        }
        message += "text2";
    }

    if (Xrm.Page.getAttribute("new_field3").getValue()) {
        if (message != null) {
            message += "\r\n";
        }
        message += "text3";
    }

    //Add more fields as required
    Xrm.Page.getAttribute("new_multi").setValue(message);
}

Viewing all articles
Browse latest Browse all 87499

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>