Closed AArndtDev closed 9 months ago
The EarlyBoundGenerator supports an option to keep them as Option Sets, rather than typed enums.
Hi Daryl, thanks for the reply! We have successfully used the /legacyMode option for CrmSvcUtil.exe, but couldn't find an equivalent for PAC ModelBuilder utility. We're running it with options specified on this page: https://learn.microsoft.com/en-us/power-platform/developer/cli/reference/modelbuilder#pac-modelbuilder-build
We could use your XrmToolbox tool in the meantime, thanks for the suggestion.
@AArndtDev sorry the massive delay on responding to this, Presenting Options items as option sets is something that we moved away from in the DVMB intentionally. We made that choice as it's a cleaner in IntelliSense and the enum type is a bit more accessible to folks.
I understand that it may be a bit disruptive to move over, and I am sorry about that. We decided that snaping to more .net standard way of addressing what is an enum was more appropriate for class gen. We add additional metadata about the enum in attributes associated with the enum.
thanks.
The CrmSvcUtil tool that many organizations used for many years to facilitate early bound code used to treat Optionsets as Optionsets and the Optionset cs file could be used with early bound code using supported CRM SDK techniques to set those fields. I would love a /legacyMode option in PAC ModelBuilder so that I could continue to code that way rather than massive refactoring to accommodate the newer enum structure. I would guess there are many organizations out there that also would benefit from being able to maintain proven and tested code without needing to change everything and re-test.