How Do I Cast Enums Correctly in SalesLogix?

Question: My History.Type is now an enums.  The below returns the message, “cannot convert type ‘int’ to ‘System.Enum'”

objH.StartDate = DateTime.Now;
objH.Duration = 0;
objH.Timeless = false;
objH.Description = this.pklStatus.Text;
objH.Attachment = false;

//write the record

How do I cast enums correctly?

Answer: You need to make the following change –

objH.Type = Sage.Entity.Interfaces.HistoryType.atNote

Submit a Comment

Your email address will not be published. Required fields are marked *

Subscribe To Our Newsletter

Join our mailing list to receive the latest Infor CRM (Saleslogix) and Creatio (bpm'online) news and product updates!

You have Successfully Subscribed!