callback a gallery in xml ribbon

  • Thread starter Thread starter khoick245
  • Start date Start date
K

khoick245

hi all. i built a gallery on a xml ribbon. in xml file, the gallery ha
structure:

<gallery id="glrSymbolic"
getItemLabel="glrSymbolic_getItemLabel">

<item id="id1" label="%LastName%" />
<item id="id2" label="%FirstName%" />
<item id="d3" label="%UserName%" />
<item id="id4" label="%Email%" />
</gallery>


in the cs file. i callback event getItemLabel

public string glrSymbolic_getItemLabel(Office.IRibbonControl control
string index)
{
switch (index)
{
case "id1":
return "%LastName%";
case "id2":
return "%FirstName%";
case "id3":
return "%UserName%";
case "id4":
return "%Email%";
default:
return String.Empty;
}
}

my purpose is that i want to get the label of items in the galler
whenever i choice a item from gallery but it's not work. can you giv
me some suggestions
 
Back
Top