我目前使用InvalidPluginExecutionException
發送消息給用戶,但事實證明,該消息是英文"Business Process Error"
超出該錯誤框出現按鈕"download log file"
。這不是錯誤,因爲用戶正在嘗試複製記錄,如代碼中所示。有沒有其他的方式,而不必使用InvalidPluginExecutionException
來顯示警報?如何通過插件向用戶發送警報而不使用InvalidPluginExecutionException?
QueryExpression query1 = new QueryExpression();
query1.ColumnSet = new ColumnSet(true);
query1.EntityName = "new_appraisers";
EntityCollection ec = service.RetrieveMultiple(query1);
if (ec.Entities.Count <= 0)
{
log.Tb_Log_Create("Appraiser created");
}
else
{
foreach (Entity app in ec.Entities)
{
if (app["fcg_appraiser"].ToString() == name)
{
log.Tb_Log_Create("appraiser allready exist");
throw new InvalidPluginExecutionException("The name allready exists");
}
if (app["new_login"].ToString() == login)
{
log.Tb_Log_Create("appraiser allready exist");
throw new InvalidPluginExecutionException("The login allready exists.");
}
}
}
這一切都不是在2011年CRM提供(也許哈克HTML作品,雖然) – Alex
是的,沒錯。好點子。 – nozzleman
我喜歡html smylie hack –