Genesys CTI User Forum
Genesys CTI User Forum => Genesys CTI Technical Discussion => Topic started by: govi on July 28, 2021, 03:22:23 PM
-
trying to add skill by using the below code, im able to add but it's deleting another skill and adding a new skill.
can anyone advise the issue in below code
=====================================================================
CfgSkillLevel skillToADD = null;
foreach (CfgSkillLevel level in Generic.agent.ConfPerson.AgentInfo.SkillLevels)
{
level.Skill.Name = "Internal_routing";
skillToADD = level;
break;
}
if (skillToADD != null)
{
Generic.agent.ConfPerson.AgentInfo.SkillLevels.Add(skillToADD);
Generic.agent.ConfPerson.Save();
}
-
Grab current Skills and add it into that List, then Add that List (your are adding, not appending) and Save