Hello,
In your script, you get the group name by accessing the Name property of the IADs interface. The property returns the Relative Distinguished Name (RDN) of an AD object. An RDN consists of an attribute type and attribute value in the format <attribute_type>=<attribute_value>, for example CN=My Group. To get the name of an AD object without the attribute type, you need to get the Name property of the object. For this purpose, use the Get property of the IADs interface. For example, in your code:
List<string> Groups = new List<string>();
var admUser = (IAdmTop) user;
var groups = (Object[]) admUser.MemberOf;
foreach (byte[] bytes in groups)
{
Guid guid = new Guid(bytes);
var group = GetGroup("Adaxes://<GUID=" + guid.ToString() + ">");
var name = group.Get("name");
Groups.Add(name);
}