Quantcast
Channel: CRM Development forum
Viewing all articles
Browse latest Browse all 8223

Passing Filter Criterias to custom lookup dialog (lookupsingle.aspx) in crm 2011?

$
0
0

Our Requirement: On Click of Ribbon button a dialog should open based on the search criteria?

Show Account(Ribbon Button) --> OOTB Lookup Dialogbox --> It should show all the accounts matching email address that is passed as criteria.

I am successfully able to open the account records using OOTB Lookup dialog.

Issue: How to pass filter criteria? can I pass email address as filter criteria through URL or is there any other approach.

//Get entity data. It requires oData query.
function OpenLookupWindow() {
    debugger;
    url = Xrm.Page.context.getServerUrl() + "//_controls/lookup/lookupsingle.aspx?class=&objecttypes=" + 1 + "&browse=0&DefaultType=0";
   var ret = window.showModalDialog(url,  null);
    if (typeof (ret) != "undefined") {
        alert(ret.items[0].id);
    }
}

Thank You!


Viewing all articles
Browse latest Browse all 8223

Trending Articles



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