javascript - odata query not working in ie 7 -


hi have odata query works fine in internet explorer 8 , above not internet explorer 7. hoping there kind of compatibility line can insert somewhere before go , create different query method.

function setpricelistfromcurrency() {  var pricelevel = xrm.page.getattribute("pricelevelid"); var currencyid = xrm.page.getattribute("transactioncurrencyid").getvalue(); if (currencyid == null) return; sdk.rest.retrievemultiplerecords("pricelevel","?$select=pricelevelid,name&$filter=transactioncurrencyid/id eq guid'"+currencyid[0].id.substr(1, 36)+"'&$top=1",      function (results)     {         //results handler          var pricelevelrecord = results[0];         if (pricelevelrecord != null)         {             pricelevel.setvalue(             [{             id: pricelevelrecord.pricelevelid,             name: pricelevelrecord.name,             entitytype: 'pricelevel'             }]             );         }         else         {             alert("no pricelist records available currency.");             pricelevel.setvalue(null);         }     },      function (error)     {         //error handler         alert(error.message);         pricelevel.setvalue(null);     },     function ()     {        //complete handler     }   ); 

}

this question has been answered! problem due sdk.rest comment below. internet explorer not support json.parse before version 8. may use jquery.parsejson instead


Comments

Popular posts from this blog

html - Sizing a high-res image (~8MB) to display entirely in a small div (circular, diameter 100px) -

java - IntelliJ - No such instance method -

identifier - Is it possible for an html5 document to have two ids? -