c# - Creating sub menus (folders) under the Administration menu in SAP business one 8.81 -
i developing payroll add-on sap business 1 8.81. can able add menus below last menu item comes sap application i.e. reports. trying add setup submenu payroll add-on under administration/setup menu of sap.
does know how this?
the code below shows how add menu's below reports menu of sap.
it in c# , file name gui.cs
ocreationpackage = ((sapbouicom.menucreationparams)(app.createobject(sapbouicom.bocreatableobjecttype.cot_menucreationparams))); omenuitem = this.app.menus.item("43520"); string spath = application.startuppath; //parent menu ocreationpackage.type = sapbouicom.bomenutype.mt_popup; ocreationpackage.uniqueid = "eim_payroll"; ocreationpackage.string = "eim payroll"; ocreationpackage.enabled= true; ocreationpackage.position = 15; ocreationpackage.image = spath + @"\eim_payroll_icon.bmp"; omenus = omenuitem.submenus; //if menu exists code fail omenus.addex(ocreationpackage); //get menu collection of newly added pop-up item omenuitem = this.app.menus.item("eim_payroll"); omenus = omenuitem.submenus; //create setup menu item master data ocreationpackage.type = sapbouicom.bomenutype.mt_popup; ocreationpackage.uniqueid = "setup"; ocreationpackage.string = "setup"; omenus.addex(ocreationpackage); omenuitem = this.app.menus.item("setup"); omenus = omenuitem.submenus; //get menu collection of newly added pop-up item omenuitem = this.app.menus.item("setup"); omenus = omenuitem.submenus; //create payroll menu item master data ocreationpackage.type = sapbouicom.bomenutype.mt_popup; ocreationpackage.uniqueid = "payroll1"; ocreationpackage.string = "payroll"; omenus.addex(ocreationpackage);
how add subfolders within menu items created within sap business 1?
just changed omenuitem = this.app.menus.item("43530");
omenuitem = this.app.menus.item("43525");
, worked
Comments
Post a Comment