I'm adding an image to a leaf node in code-behind like this:
rNode.ImageUrl = "images/icon_navflag.gif" |
This works fine. Now, I'd like to move the position of the image to the left about 50px within the treeview. How can I do it?
7 Answers, 1 is accepted
0
Hi Geoffrey,
You can set the position of RadTreeNode image with the following css style:
All the best,
Yana
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
You can set the position of RadTreeNode image with the following css style:
.RadTreeView .rtImg { |
position: relative; |
left: 50px; |
} |
All the best,
Yana
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Geoffrey
Top achievements
Rank 1
answered on 01 Jun 2009, 07:41 PM
I'm unable to get this to work. That is, the leaf node image does not move to the left when I make the suggested change to the CSS file. Is there an example available that shows how to set the position of an inserted leaf node image? Thanks.
0
Hi Geoffrey,
I am not able to understand the needed layout of the treeview, so could you please provide us with a screenshot? Thanks
Kind regards,
Yana
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
I am not able to understand the needed layout of the treeview, so could you please provide us with a screenshot? Thanks
Kind regards,
Yana
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Geoffrey
Top achievements
Rank 1
answered on 03 Jun 2009, 01:37 PM
Yes, I have a screenshot that shows the needed layout of the treeview. How do I post an image to this forum?
0
Hi Geoffrey,
You're not allowed to attach files in this forum, please use some online storage service to send us the image.
Best wishes,
Yana
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
You're not allowed to attach files in this forum, please use some online storage service to send us the image.
Best wishes,
Yana
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Geoffrey
Top achievements
Rank 1
answered on 09 Jun 2009, 04:26 PM
OK, it took awhile but here's a link to a JPEG that shows how we need the leaf node images to appear within a treeview:
http://www.silverchair.com/flags/flags.html
Notice the position of the "green flags" in the JPEG. Currently, when we add a green flag to a leaf node, it shows up in within the text of the leaf node. For instance, “Bibliographic” is partially obscured by a green flag (something like “Bi[ ]ographic, where [ ] indicates the position of the green flag). That is why we want to be able to move the green flags to the left about 50 px. Hope this is clear.
http://www.silverchair.com/flags/flags.html
Notice the position of the "green flags" in the JPEG. Currently, when we add a green flag to a leaf node, it shows up in within the text of the leaf node. For instance, “Bibliographic” is partially obscured by a green flag (something like “Bi[ ]ographic, where [ ] indicates the position of the green flag). That is why we want to be able to move the green flags to the left about 50 px. Hope this is clear.
0
Hi Geoffrey,
Actually the images are supposed to be aligned like in the screenshot, please check this online demo, for example.
I suppose that this is a css issue, could you please send us a simple page or live url where we could observe the problem? Thanks a lot.
Best wishes,
Yana
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Actually the images are supposed to be aligned like in the screenshot, please check this online demo, for example.
I suppose that this is a css issue, could you please send us a simple page or live url where we could observe the problem? Thanks a lot.
Best wishes,
Yana
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.