Trapping a 500 warning

Hi

I have the following transformResponse code:-

			transformResponse: function(dsResponse, dsRequest, xmlData){
			
				if (dsResponse.httpResponseCode >= 500 && dsResponse.httpResponseCode <= 599) {
					var faultString = isc.XMLTools.selectString(isc.XMLTools.parseXML(xmlData), "/soap:Envelope/soap:Body/soap:Fault/faultstring");
					dsResponse.status = -1
					if (faultString !== null) {
						dsResponse.data = faultString;
					}
				}
				
				if (dsRequest.operationType == "remove") {
					dsResponse.data = dsRequest.originalData;
				}
				
				return dsResponse;
			}			
		});

When I delete certain records in a ListGrid, I get the following “Note” dialog message:-

My transformResponse code doesn’t catch this and I am pretty sure this message is triggered because the deletion violates RI on the SQL server (not that you’d know from the message :slight_smile:

Where is the best place to intercept and handle this “Note”?

Thanks.

Hi Henryville,
By default errors are caught and handled by the central RPCManager.handleError() method.

For specific requests you can disable this by setting willHandleError to false on your request, and then checking the status / data in the callback method.

Thanks

Hi

OK - thanks for the information.

-H