Search This Blog

Friday, July 22, 2016

Get parameter value from QueryString in CRM

function ParseQueryString(query) {
    var result = {};

    if (typeof query == "undefined" || query == null) {
        return result;
    }

    var queryparts = query.split("&");
    for (var i = 0; i < queryparts.length; i++) {
        var params = queryparts[i].split("=");
        result[params[0]] = params.length > 1 ? params[1] : null;
    }
    return result;
}

var passedparams = ParseQueryString(GetGlobalContext().getQueryStringParameters()["Data"]);

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.