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

Asp .net RadDatePicker in CompositeControl

1 Answer 65 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Marek
Top achievements
Rank 1
Marek asked on 07 Dec 2012, 11:47 AM
I have problem with RadDatePicker inside composite control. My composite control looks like this:
...
        protected override void CreateChildControls()
        {
            this.Controls.Clear();
            this.Calendar = new RadDatePicker
            {
              ID = "Calendar",
                Width = new Unit(100, UnitType.Percentage)

            };
            this.Controls.Add(this.Calendar);
        }

        protected override void Render(HtmlTextWriter writer)
        {
            this.AddAttributesToRender(writer);
            writer.RenderBeginTag(HtmlTextWriterTag.Div);
            this.Calendar.RenderControl(writer);
            writer.RenderEndTag();
        }
...
When I launch the project, the callendar appers on the page. The problem is that firebug logs error, and after click on the calendar's button nothing happens. The error:

TypeError: a is undefined
...alizer._serverTypeFieldName&&f!==0){d[f++]=d[0];d[0]=e}else d[f++]=e}if(i)d.sort...
Teleri...cacbc31

1 Answer, 1 is accepted

Sort by
0
Maria Ilieva
Telerik team
answered on 13 Dec 2012, 11:38 AM
Hi,

Could you please try to add another script control in your custom composite control and verify if the same error appears? Also please try to firstly add the RadDatePicker control to the control collection and then set its properties.

Kind regards,
Maria Ilieva
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
General Discussions
Asked by
Marek
Top achievements
Rank 1
Answers by
Maria Ilieva
Telerik team
Share this question
or