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. Image for the cookie policy date

remembering name or id of last item clicked of barmanager

Hi,

can we get the name of last baritem clicked ie before the currently clicked bar item.If yes, How?????


Thanks
Ranju Malhotra


1 Reply

AD Administrator Syncfusion Team March 27, 2008 11:15 AM UTC

Hi Ranju,

Thank you for your interest in Syncfusion Products.

Currently we dont have any specific property or method that traces the previously clicked bar item. As a work around, we need to save the item when it is clicked and can retain it when next item is being clicked. Please find the code snippet that illustrates this:

private void BarItem_Click(object sender, System.EventArgs e)
{
BarItem barItem = null ;
if(sender is BarItem)
{
BarItem = sender as BarItem;
this.MyTraceLine(barItem.Text + " Clicked.");
}
if (Bar_before != null)
{
this.MyTraceLine(Bar_before.Text + " is previously clicked baritem");
}
Bar_before = barItem;
}


Please find the simple sample in the following link:

http://websamples.syncfusion.com/samples/Tools.Windows/F72489/main.htm

Please let me know if any concerns.

Regards,
Fathima



Loader.
Live Chat Icon For mobile
Up arrow icon