how to loop on all buttons (toolstripbutton) in Ribboncontroladv

hi
how I can loop on all buttons in RibbonControlAdv inside (ToolStripTabItem1>> ToolStripEx)?
anybody can help me?

1 Reply 1 reply marked as answer

EM Elakkiya Muthukumarasamy Syncfusion Team February 8, 2021 11:31 AM UTC

Hi Mohamad, 
 
Greetings from Syncfusion. 
 
We have checked your reported query “how to loop on all buttons (toolstripbutton) in Ribboncontroladv” and prepared a sample for your reference and this can be downloaded from the below location. In our sample, we have ToolStripTabItem named as file and added the ToolStripButtons to the ToolStripEx.We can able to loop all the ToolStripButtons from toolStripExFile1.Items.Please refer the below code snippet for the same 
 
Code snippet  
 
 
for(int i = 0; i < toolStripExFile1.Items.Count; i++) 
{ 
if(toolStripExFile1.Items[i] is ToolStripButton) 
{ 
//type your code here based on your requirement  
} 
} 
 
 
 
 
Please try it with the provided solution and let us know if you need any further assistance on this. We will be glad to assist you. 
 
Regards, 
Elakkiya 


Marked as answer
Loader.
Up arrow icon