Question
CIGNA
US
Last activity: 27 Jun 2017 10:41 EDT
Activity call via javascript(pega.u.d.reloadSection) not working in IE. (Pega v7.2.2)
Hi All ,
We are using custom control to reload the section based conditions ,Please find the below code. .
<script>
function DConfirm(Status){
var oSafeUrl = new SafeURL("Class.Activity1");
oSafeUrl.put("Caption","Delete");
var callback = {
success : function(oResponse)
{
var strReturn = oResponse.responseText;
if(oResponse.responseText == "NoResults"){
alert("No records to delete.");
}
else if(oResponse.responseText == "NoRowsSelected")
{
alert("Record 1.");
}
else if(oResponse.responseText == "InvalidSelection")
{
alert(" Record 2 .");
}
else if(oResponse.responseText == "success")
{
var r= confirm("Are you sure you want to delete the selected records?");
if(r)
{
if(Status=="E"){
pega.u.d.reloadSection(pega.u.d.getSectionByName('Section 1','',''), 'Activity 2', '', false , true, '-1', false); }
else{
pega.u.d.reloadSection(pega.u.d.getSectionByName('Section 2','',''), 'Activity 2', '', false , true, '-1', false); }
}
}
else {
alert(oResponse.responseText);
}
},
failure : function(oResponse) {
alert("Update Failure");
}
};
var request = pega.util.Connect.asyncRequest('GET',oSafeUrl.toURL(),callback);
}
</script>
Hi All ,
We are using custom control to reload the section based conditions ,Please find the below code. .
<script>
function DConfirm(Status){
var oSafeUrl = new SafeURL("Class.Activity1");
oSafeUrl.put("Caption","Delete");
var callback = {
success : function(oResponse)
{
var strReturn = oResponse.responseText;
if(oResponse.responseText == "NoResults"){
alert("No records to delete.");
}
else if(oResponse.responseText == "NoRowsSelected")
{
alert("Record 1.");
}
else if(oResponse.responseText == "InvalidSelection")
{
alert(" Record 2 .");
}
else if(oResponse.responseText == "success")
{
var r= confirm("Are you sure you want to delete the selected records?");
if(r)
{
if(Status=="E"){
pega.u.d.reloadSection(pega.u.d.getSectionByName('Section 1','',''), 'Activity 2', '', false , true, '-1', false); }
else{
pega.u.d.reloadSection(pega.u.d.getSectionByName('Section 2','',''), 'Activity 2', '', false , true, '-1', false); }
}
}
else {
alert(oResponse.responseText);
}
},
failure : function(oResponse) {
alert("Update Failure");
}
};
var request = pega.util.Connect.asyncRequest('GET',oSafeUrl.toURL(),callback);
}
</script>
<table border="0" class="buttonMainTable" cellspacing="0" cellpadding="0" <pega:when test='param.TableId != ""'>id="<pega:reference name="$save(strTableId)"/>"</pega:when> >
<tr>
<td class="buttonTdLeft"> </td>
<td nowrap class="buttonTdMiddle">
<button class="buttonTdButton" <pega:withPage name="pyDisplayHarness"><pega:when name='DeleteVisibleWhen'>disabled </pega:when></pega:withPage> onclick="DConfirm('<pega:reference name="Param.Status"/>');" PEGA_VERSION="HTMLPROPERTY">
<pega:when test='param.Image != ""'><img style="padding-right:3px;vertical-align:middle"
<%
String strImage = tools.getSaveValue("strImage");
if(strImage.indexOf(".")!=-1)
tools.appendString("src=" + strImage);
else
tools.appendString("class=" + strImage);
%>
></img></pega:when>Delete</button>
</td>
<td class="buttonTdRight" onclick="if(typeof(pega) !='undefined' && pega.u.d) pega.u.d.fireButtonClick(this.parentNode);"> </td>
</tr>
</table>
</head>
</html>
--------------------------------------------------
The above code works fine in pega 6.1 not in pega 7.2.2
Please let me know any once facing the similar issue.
Thanks.
***Moderator Edit: Vidyaranjan | Updated Categories***