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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Help for right image overlaying.

Thread ID:





42649 Apr 4,2006 06:26 AM UTC Apr 7,2006 09:36 AM UTC WinForms 2
Tags: Tools
Administrator [Syncfusion]
Asked On April 4, 2006 06:26 AM UTC

I see that you only show the left image overlay in the samples. Is it possible to show the left image and the right image overlay in the same sample. Because I am able to do only one at a time but my application consists of both the images. Please see my sample attached and help me. Thanks in advance. regards, Joy

Deepa TS [Syncfusion]
Replied On April 4, 2006 09:14 AM UTC

Hi Joy, Sorry for the inconvenience caused. I have created a sample as per your specification.The sample illustrates the possiblity to show the LeftImage overlay and the RightImage overlay in the same sample. The property "RightImagesX" of the node plays a great role in setting the RightImage overlay.It describes the horizontal distance between the treeBorder and the beginning of the node''s right image. private void treeViewAdv1_AfterNodePaint(object sender, Syncfusion.Windows.Forms.Tools.TreeNodeAdvPaintEventArgs e) { Point pt=this.treeViewAdv1.PointToClient(new Point(MousePosition.X,MousePosition.Y)); TreeNodeAdv node=this.treeViewAdv1.GetNodeAtPoint(pt); node = this.treeViewAdv1.SelectedNode; if(node!=null) { if(node.Text=="Asia" ||node.Text=="India"||node.Text=="China"||node.Text=="Europe" || node.Text=="Britain"||node.Text=="France"||node.Text=="North America"|| node.Text=="United States"||node.Text=="Canada") { //setting the LeftImage overlay pt = new Point(node.LeftImagesX, node.TextAndImageBounds.Y); e.Graphics.DrawImage(imageList1.Images[26], pt ); } else { //setting the RightImage overlay pt = new Point(node.RightImagesX, node.TextAndImageBounds.Y); e.Graphics.DrawImage(imageList2.Images[9], pt ); } } } Please take a look at the attached sample and let me know if this helps you. Thanks for your interest in Syncfusion products. Regards, Deepa.


Administrator [Syncfusion]
Replied On April 7, 2006 09:36 AM UTC

Hi deepa, yes this works fine. Thanks.


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon 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.Close Icon