1. lingaiah T
  2. PowerBuilder
  3. Saturday, 4 September 2021 16:00 PM UTC

Dear Team,

I would like to create a ribbonbar menu from table data.

Example: I have a table name : menus_table

Create table menus_table
(menu_text varchar(50), menu_level_1 varchar(2) ,menu_level_2 varchar(2),menu_level_3 varchar(2)
)


insert into menus_table values ( 'File',1,0,0)
insert into menus_table values ( 'Cut',1,1,0)
insert into menus_table values ( 'Copy',1,2,0)
insert into menus_table values ( 'pastespecial',1,3,1)
insert into menus_table values ( 'pastespecial -Values ',1,3,1)
insert into menus_table values ( 'pastespecial - Formats',1,3,1)

/***********************************************************/

Ribbon Bar Menu

/********************************************************/

Read from table and Display like below

- File   (Category)  

                  (panel)

   --  Cut   Largebutton    Copy (largebutton)     Pastespecial ( Dropdown)

                                                                   --- Values (Menuitems)

                                                                    ---- Formats (Menuitems)

 

Please see the attached file (example)

 

Thanks in advance for the group/team

Attachments (1)
Kai Zhao @Appeon Accepted Answer Pending Moderation
  1. Tuesday, 7 September 2021 03:20 AM UTC
  2. PowerBuilder
  3. # 1

Hi Lingaiah,

You can use functions like InsertCategory, InsertLargeButton, and SetMemu, etc. to initiate RibbonBar according to the data in the table. But this depends on the data and the RibbonBar style you want, there is no common script.

The case in your screenshot has an example of using PowerScript to initiate RibbonBar. Please refer to function wf_init_ribbonbar in sales_main.pbl/w_mdi for details.

Regards,
ZhaoKai

Comment
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.