In the following C# code, cboRole returns a Guid.
I\'m then trying to use it in a switch statement to do some actions.
cboRole can return only 4 different G
Your switch statements are in upper-case while your ToStringEx() returns the Guid in lower-case.
ToStringEx()
Guid
You can use
switch (cboRole.EditValue.ToStringEx().ToUpper())
or modify your case statements.
case