This is a migrated thread and some comments may be shown as answers.

RadTree View inside combobox doesnt display the gridlines

6 Answers 80 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Ravi Keshwani
Top achievements
Rank 1
Ravi Keshwani asked on 20 Apr 2010, 09:30 AM
Hi telerik,
 
 I am dunamically loading the usercontrols in pageviews. I have a radcombo having radtreeview. Its not displaying LineImages. I have set 

ShowLineImages

 

="true".

Image of the radcombo attached.

 

6 Answers, 1 is accepted

Sort by
0
Yana
Telerik team
answered on 20 Apr 2010, 10:11 AM
Hello Ravi,

Can you send us a live url demonstrating this issue? Thanks

Kind regards,
Yana
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Ravi Keshwani
Top achievements
Rank 1
answered on 20 Apr 2010, 10:27 AM
Hello Yana,

 I am doing this in my local environment. I can provide u the below details.

Radcombo Tag in a usercontrol added dynamically in a page view by clicking add new custom command button of radgrid.

 

<telerik:RadComboBox ID="rcbAttendeeType" runat="server" EmptyMessage="Select Attendee Type" Skin="Sunset"

 

 

AutoPostBack="true" ShowToggleImage="True" Style="vertical-align: middle;" OnClientDropDownOpened="OnClientDropDownOpenedHandler"

 

 

HighlightTemplatedItems="false" OnClientDropDownClosed="onDropDownClosing" TabIndex="28">

 

 

<ItemTemplate>

 

 

<div id="div1" onclick="StopPropagation(event);">

 

 

<telerik:RadTreeView ShowLineImages="true" runat="server" ID="rtvAttendeeType" EnableAjaxSkinRendering="true"

 

 

Skin="Sunset" EnableEmbeddedSkins="true" EnableViewState="true" CheckBoxes="false"

 

 

Height="100%" OnClientNodeClicking="nodeClicking" OnNodeClick="rtvAttendeeType_NodeClick">

 

 

<DataBindings>

 

 

<telerik:RadTreeNodeBinding Expanded="True" />

 

 

</DataBindings>

 

 

</telerik:RadTreeView>

 

 

</div>

 

 

</ItemTemplate>

 

 

<Items>

 

 

<telerik:RadComboBoxItem Text="" />

 

 

</Items>

 

 

</telerik:RadComboBox>

 


On preRender event of the page I have code that bind the tree as below

 

if (rcbAttendeeType.Items != null && rcbAttendeeType.Items.Count >= 0)

 

{

Telerik.Web.UI.

RadTreeView rtvAT = rcbAttendeeType.Items[0].FindControl("rtvAttendeeType") as Telerik.Web.UI.RadTreeView;

 

 

if (this.Parent.Page.Request.Url.AbsolutePath.Contains("ShowAttendees.aspx")

 

||

this.Parent.Page.Request.Url.AbsolutePath.Contains("OnlineRegistration.aspx"))

 

{

 

IEnumerable<epp2ClientPL.AttendeeTypesProperties> attendeeTypes = Common.LoadAttendeeTypes(EventId);

 

attendeeTypes =

from attTypes in attendeeTypes

 

 

where attTypes.VisibleToPublic.Equals(true)

 

 

select attTypes;

 

rtvAT.DataTextField =

"Name";

 

rtvAT.DataValueField =

"Id";

 

rtvAT.DataFieldID =

"Id";

 

rtvAT.DataFieldParentID =

"ParentId";

 

rtvAT.DataSource = attendeeTypes;

rtvAT.DataBind();

}

 

else

 

{

 

Common.LoadAttendeeTree(rtvAT, EventId);

 

}

rcbAttendeeType.Items[0].Text =

"--- Select Attendee Type ---";

 

rcbAttendeeType.Items[0].Value = epp2ClientPL.

Common.GUID_DEFAULT;

 

}


ddsfdfdf
0
Ravi Keshwani
Top achievements
Rank 1
answered on 22 Apr 2010, 04:57 AM
Hello Yana,

    I am awaiting for the solution.

Thanks
0
Yana
Telerik team
answered on 22 Apr 2010, 02:15 PM
Hi Ravi Keshwani,

I've attached my test pages (based on your code) to demonstrate that the images can be seen. What am I missing?

Greetings,
Yana
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Ravi Keshwani
Top achievements
Rank 1
answered on 23 Apr 2010, 05:21 AM
Hi yana,

 "This is not working in IE8" working fine in opera and firefox.

 Thanks for the reply. I have run  the code u have sent its working fine. But if you see my scenario is something different.
 First of all I am following "TabStrip / Load on Demand RadPageView" sample.
 In a page I have loaded a usercontrol dynamically which is having a radgrid with a custom toolbar with a button.
 Clicking on this button loads another usercontrol dynamically in a pageview.
 The radcombo with radtree inside it is also binded in the prerender event of the usercontrol added dynamically.

Below code will be useful to reproduce this issue.

 

protected void RadTabStrip1_TabClick(object sender, RadTabStripEventArgs e)

 

{

 

AddPageView(e.Tab);

e.Tab.PageView.Selected =

true;
}

 

 

public void AddPageView(RadTab tab)

 

{

 

RadPageView pageView = new RadPageView();

 

pageView.ID = tab.Value;

 

RadMultiPage1.PageViews.Add(pageView);

 

pageView.CssClass =

"pageView";

 

tab.PageViewID = pageView.ID;
}

 

 

 

 

protected void RadMultiPage1_PageViewCreated(object sender, RadMultiPageEventArgs e)

 

{

 

string userControlName = "UserControls/"+e.PageView.ID + ".ascx";

 

 

Control userControl = Page.LoadControl(userControlName);

 

userControl.ID = e.PageView.ID +

"_userControl";

 

e.PageView.Controls.Add(userControl);

 

}

 

protected

 

override void OnPreRender(EventArgs e)

 

{

 

base.OnPreRender(e);

 

 

 

 

    if (rcbAttendeeType.Items != null && rcbAttendeeType.Items.Count >= 0)
                    {
                        Telerik.Web.UI.RadTreeView rtvAT = rcbAttendeeType.Items[0].FindControl("rtvAttendeeType") as Telerik.Web.UI.RadTreeView;

                        string attendeeTypeId = CurrentUser.AttendeeTypeId != null ? CurrentUser.AttendeeTypeId.ToString() : string.Empty;
                        if (rtvAT.Nodes != null && rtvAT.Nodes.Count > 0 && attendeeTypeId.Length > 0)
                        {
                            Telerik.Web.UI.RadTreeNode node = rtvAT.FindNodeByValue(attendeeTypeId);

                            if (node != null && node.Text.Length > 0)
                            {
                                rcbAttendeeType.Items[0].Text = node.Text;
                                rcbAttendeeType.Items[0].Value = node.Value;

                                rtvAT.FindNodeByText(node.Text).Selected = true;
                            }
                        }
                    }


}

0
Yana
Telerik team
answered on 28 Apr 2010, 03:02 PM
Hi Ravi Keshwani,

I've tried this but still cannot reproduce the issue. Could you please try to isolate it in a simplified project and send it to us so we to be able to observe it? Thanks

Greetings,
Yana
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Tags
ComboBox
Asked by
Ravi Keshwani
Top achievements
Rank 1
Answers by
Yana
Telerik team
Ravi Keshwani
Top achievements
Rank 1
Share this question
or