public static Letter GetLetter(IOrganizationService ser, Guid letterid, ColumnSet columnset)
{
try
{
QueryExpression query = GetQueryExpressionSingle("letter", "activityid", letterid, columnset);
EntityCollection ec = ser.RetrieveMultiple(query);
if (ec != null && ec.Entities.Count == 1)
return (Letter)ec.Entities[0];
else
return new Letter();
}
catch (Exception ex)
{
throw ex;
}
}
GetQueryExpressionSingle metodu
Metot Kullanımı
Letter letter = CrmManagerStatic.GetLetter(crmService, item, new ColumnSet(new string[] { "activityid", "regardingobjectid", "ownerid", "activitytypecode", "actualdurationminutes", "statecode", "statuscode" }));
Hiç yorum yok:
Yorum Gönder