I want to Display user list in Ribbon Dropdown Button

Posted by: shivambhardwajfdb on 11 May 2022, 3:59 am EST

  • Posted 11 May 2022, 3:59 am EST

    const UserList = ["abc@gmail.com","abc@gmail.com","abc@gmail.com","abc@gmail.com","abc@gmail.com"];
    var email = {
    label: "Users",
    thumbnailClass: "",
    type: "dropdown",
    commandGroup: {
    children: [
    direction: "vertical",
    commands: ["cmdUserList"],
    const allButtons = config.ribbon[0].buttonGroups.slice(-8);
    config.ribbon[0].buttonGroups = [
    config.commandMap = {
    cmdUserList: {
    title: "list of users",
    text: UserList, //location.state.data.data.Lu.Bv stores the value of the user email address
    type: "dropdown",
    iconClass: "cmdUserList",
    style: "",
    bigButton: "true",
    commandName: "cmdUserList",
    execute: async (context, propertyName, fontItalicChecked) => {
  • Replied 11 May 2022, 5:06 pm EST

    Hi Shivam,

    You need to pass the array containing name-value pair to the dropDownList property when defining the command under config.commandMap.

    For example, you can refer to the following code that I have created for you(I have modified the code shared by you): https://jscodemine.grapecity.com/share/6cqDQbeiMUeAWy2YJazGsw/

    If you want the combobox similar to the Font ComboBox, you can also refer to the following sample: https://jscodemine.grapecity.com/share/rRdQM24Qu0WEAP8Tfh_uKA/

    Please let us know if you need further assistance on your query. We would be happy to help you.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels