public partial class pgc_BookingRuleRequest : Microsoft.Xrm.Sdk.OrganizationRequest { ... snip ... }
public partial class pgc_BookingRuleResponse: Microsoft.Xrm.Sdk.OrganizationRequest { ... snip ... }
It's not possible to set the properties in the pgc_BookingRuleResponse object because all the properties are read-only.
The model builder does not provide string values for the message properties (it does for entity properties, e.g. account.Fields.pgc_CustomField = "pgc_customfield"; )
Note: The EBG adds static Fields to the response class, e.g.
public partial class AnS_BookingRuleResponse : Microsoft.Xrm.Sdk.OrganizationResponse
{
public static class Fields
{
public const string Success = "Success";
public const string Message = "Message";
}
Note: The EBG also allows for the properties to be writable:
public string Message
{
get
{
if (this.Results.Contains("Message"))
{
return ((string)(this.Results["Message"]));
}
else
{
return default(string);
}
}
set // <--- This is added by EBG
{
this.Results["Message"] = value;
}
}
It would be great if pac modelbuilder build was tweaked include both the static fields and the setting of properties.
It does not seem to be possible to set output parameters for a plugin associated with a custom API without using a magic string, e.g. 'Message'
The following command will output an earlybinding for the message pgc_BookingRule (for an Action or CustomAPI)
i.e.
It's not possible to set the properties in the pgc_BookingRuleResponse object because all the properties are read-only.
The model builder does not provide string values for the message properties (it does for entity properties, e.g.
account.Fields.pgc_CustomField = "pgc_customfield";
)Workarounds are:
Note: The EBG adds static Fields to the response class, e.g.
Note: The EBG also allows for the properties to be writable:
It would be great if
pac modelbuilder build
was tweaked include both the static fields and the setting of properties.