We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

When I right click on menu bar, items are not sorted.

Thread ID:

Created:

Updated:

Platform:

Replies:

75457 Jul 26,2008 01:27 AM Aug 11,2008 12:24 AM Windows Forms 11
loading
Tags: Tools
Administrator [Syncfusion]
Asked On July 26, 2008 01:27 AM

Hi,

When I right click on my top menubar, the toolbar list comes up. But they are not sorted in any order. The samething happens in my View->Toolbars menu item (ToolbarListBarItem).

Could these toolbar names be sorted ascending order?

Thanks,
- Kishan


Administrator [Syncfusion]
Replied On July 28, 2008 07:41 AM

Hi Kishan,

Sorry for the delay response.

You can use the ParentBarItem.Items.Sort method to sort the baritems in a ParentBarItem using the specified comparer. Here is a code snippet that shows you "How to sort the barItems depend on its Text property in a ParentBarItem?".

[C#]

this.parentBarItem1.Items.Sort(new SortByBarItemClass());

public class SortByBarItemClass : IComparer
{
public int Compare(object x, object y)
{
BarItem _barX = x as BarItem;
BarItem _barY = y as BarItem;
return _barX.Text.CompareTo(_barY.Text);
}
}

I have attached the sample for your reference. You can download the sample from the following page.
http://websamples.syncfusion.com/samples/Tools.Windows/F75457/main.htm

Please refer to the sample and let me know if you have any questions.

Thank you for interest in Syncfusion Products.

Regards,
Hema


Administrator [Syncfusion]
Replied On July 29, 2008 04:49 AM

Hi Hema,
Thanks for reply.

I have some items like 'CCC', 'BBB', 'AAA' in Toolbars tab of mainFrameBarManager as mentioned in the attached file.
Now, when I right click on menu bar those items('CCC', 'BBB', 'AAA') are comming up, but not sorted.

I want to sort those items.

Thanks
-Kishan




Tools_WF_XPMenus_Sort_9a590253.zip

Administrator [Syncfusion]
Replied On July 31, 2008 02:00 AM

Hello Hema,

Please give me reply, it is very urgent.

Thanks
-Kishan


Administrator [Syncfusion]
Replied On July 31, 2008 06:27 AM

Hi Kishan,

I regret for the delay in getting back to you on this requirement.

We are working on this issue and we will update you before 7-Aug-2008.

Thank you for your patience.

Regards,
Hema


Administrator [Syncfusion]
Replied On August 7, 2008 04:53 AM

Hi Kishan,

Thank you for your patience.

MenuItemMergeOrder property is used to set the order of Toolbar in Context menu. Herewith I have attached the modified sample for your reference. Please go through the sample and let me know if you have any other issues.

Sample Link: http://websamples.syncfusion.com/samples/Tools.Windows/F75457_1/main.htm

Thank you for choosing Syncfusion products.

Regards,
Hema


Administrator [Syncfusion]
Replied On August 7, 2008 05:31 AM

Hi Hema,

It works. Thanks for your help.

Thanks
-Kishan


Administrator [Syncfusion]
Replied On August 7, 2008 06:14 AM

Hi Kishan,

Thank you for the update.

Regards,
Hema



Administrator [Syncfusion]
Replied On August 8, 2008 01:38 AM

Hi Hema,

Sorry, I have come again.
Please run attached .cs file.

On 'Customize' popup window add new bar item 'FFF' using 'New' button.
I want to sort such criteria also.

Let me know whether you understand or not.

Thanks
-Kishan.



Tools_WF_XPMenus_Sort_82de09a6.zip

Administrator [Syncfusion]
Replied On August 8, 2008 08:54 AM

Hi Kishan,

Thank you for your patience.

Please refer the modified sample as per your requirement and let me know if you have any queries.
Sample Link: http://websamples.syncfusion.com/samples/Tools.Windows/F75457_2/main.htm

Thank you for your interest in Syncfusion Products.

Regards,
Hema


Administrator [Syncfusion]
Replied On August 9, 2008 02:18 AM

Hi Hema,

Thanks for quick reply.
It is working.

Regards
-Kishan



Administrator [Syncfusion]
Replied On August 11, 2008 12:24 AM

Hi Kishan,

Thank you for the update.

Regards,
Hema


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;