Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
161 views
Hi,
I am using Rad Calendar for selecting  multiple dates . I need to select many dates for some back end computation.
I also need to bind the dates again with the calendar control while retrieving the dates from DB. I dono the exact way of achieving this. I used the following code but it giving problem in "get_selectedDates()" function. I am using the latest Version only. Pls help me
 function getSelected() {
            var d, text = '';
            var calendar = "<%= RadCalendar1.ClientID %>";
            var dates = calendar.get_selectedDates();
            for (var i = 0; i < dates.length; i++) {
                var date = dates[i];
                d = date[1] + '/' + date[2] + '/' + date[0];

                if (i == dates.length - 1) {
                    text = text + d;
                }
                else {
                    text = d + ',' + text;
                }
            }
            var textbox = document.getElementById('TextBox1');
            textbox.value = text;
        } 

Thanks,
Jeevitha

Pavlina
Telerik team
 answered on 16 Nov 2009
1 answer
126 views
Hi,
i use RadAjaxManager in radgrid telerik q3 2009 in my dnn module and i see this error:
Object reference not set to an instance of an object.(i use this sample   http://demos.telerik.com/aspnet-ajax/ajax/examples/manager/dynamicajaxsettings/defaultcs.aspx?product=grid   )
this is pieces my code that errror occur this:              
 (RadAjaxManager.GetCurrent(this.Page) as RadAjaxManager).AjaxSettings.AddAjaxSetting(editButton, this.Page.FindControl("pnlgrd"), this.Page.FindControl("RadAjaxLoadingPanel1") as RadAjaxLoadingPanel);
please help me to solve this problems.
very thanks.

Vlad
Telerik team
 answered on 16 Nov 2009
1 answer
243 views
Hello,

I would like to update my text to database and reloading it later from database. Problem is MyRadTextBox.Text replace carriage return by one space.
Is it possible to save carriage return ?

Thank you.
luc bonenfant
Top achievements
Rank 1
 answered on 16 Nov 2009
1 answer
174 views
Hi Everybody,

I developed a little project for try to undertand better the working of radcalendar control. In this development I havent knw how to change the special dates style.

In the page, there are two radcalendar controls and a button. The user selects any date from first radcalendar and then the user clicks on button.

There is a event button that gets all dates and then adds as special dates in the second  radcalendar. Well, both radcalendar control has the style of Web20. I'd like that the special dates will be the same style of disable dates or dates that be outside of period of time.

This is the event button code:

foreach

 

(RadDate item in RadCalendar1.SelectedDates)

 

{

 

RadCalendarDay day = new RadCalendarDay();

 

day.Date = item.Date;

day.IsDisabled =

true;

 

day.IsSelectable =

false;

 

day.ItemStyle.CssClass =

"calendarHolidays";

 

RadCalendar2.SpecialDays.Add(day);

 

}

Following, css:

 

.calendarHolidays

 

a

 

{

 

color: red !Important;

 

 

background-color: #f2f2f2 !Important;

 

}

this class is inside of Calendar.Web20 css.

Could anyone help me plase??/

Thank you for all attention,

Carlos

Pavlina
Telerik team
 answered on 16 Nov 2009
4 answers
171 views
Probably a really obvious mistake, but I have been scratching my head for a couple of hours now. I can't seem to get javascript to find my tree view, I started off in a splitter area, and then took it out, and have now created the most basic page I can to try and find a tree view with the Javascript API.

When I run this I get a Javascript error telling me

"Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET CLR 1.1.4322; InfoPath.2; OfficeLiveConnector.1.3; OfficeLivePatch.0.0)
Timestamp: Mon, 16 Nov 2009 13:32:20 UTC

Message: 'tree' is null or not an object
Line: 67
Char: 18
Code: 0"
 

So it's not finding the tree, never mind the nodes. Any suggestions would be gratefully received.

Jon

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default4.aspx.cs" Inherits="LMS_LMS_Default4" %> 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> 
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
 
<html xmlns="http://www.w3.org/1999/xhtml" > 
<head runat="server">  
    <title>Untitled Page</title> 
</head> 
<body> 
    <form id="form1" runat="server">  
<asp:ScriptManager ID="ScriptManager1" runat="server">    
</asp:ScriptManager>    
    <div> 
    <telerik:RadTreeView ID="LessonTree" runat="server">    
    <CollapseAnimation Duration="100" Type="OutQuint" />    
    <ExpandAnimation Duration="100" />    
    <Nodes>    
        <telerik:RadTreeNode Text="Item1"> </telerik:RadTreeNode>    
        <telerik:RadTreeNode Text="Item2"> </telerik:RadTreeNode>    
        <telerik:RadTreeNode Text="Item3"> </telerik:RadTreeNode>    
    </Nodes>    
</telerik:RadTreeView>    
 
 
<script type="text/javascript">    
   var tree = $find("<%= LessonTree.ClientID %>");  
   for (var i=0; i<tree.get_nodes().get_count();i++)     
   {           
       var node = tree.get_nodes().getNode(i);           
       alert(node.get_text());     
   }  
 
</script>    
 
    </div> 
    </form> 
</body> 
</html> 
 
Jonathan
Top achievements
Rank 1
 answered on 16 Nov 2009
1 answer
114 views
I am trying to change the font size and weight of appointment text shown in scheduler from code behind but it is not taking any effect.

 protected void Page_Init(object sender, EventArgs e)
    {

        List<Appointment> list = (List<Appointment>)this.VacationScheduler.Provider.GetAppointments(this.VacationScheduler);

        foreach (Appointment p in list)
        {
            p.CssClass = "boldy";
            p.Font.Italic = true;
        }
    }

CSS:
-------
 <style type="text/css">
    
    .boldy
    {
        font-style:italic !important;
        font-weight:bold !important;
    }
    
    </style>

It is not taking effect.

Any suggestions?
Peter
Telerik team
 answered on 16 Nov 2009
1 answer
86 views
Hello,

I'm using RadGrid and I have following column:

 <telerik:GridTemplateColumn  HeaderText="MyField" DataType="System.String" >
          <ItemTemplate>
                     <%# getSomeInfo() %>
          </ItemTemplate>
</telerik:GridTemplateColumn>

'getSomeInfo' is not conected to any datasource field.

Please can you help me organise filter and sorting capability of this column

Best Regards
Zl. Rusev

Vlad
Telerik team
 answered on 16 Nov 2009
1 answer
127 views
Hello

I am trying to make a bar chart display the labels below the X axis where now 0, 1, 2 , 3, 4 etc numbers can be found and not on the bar how they are displayed by default.

Thanks in advance for your help
Mihai Dinculescu
Top achievements
Rank 1
 answered on 16 Nov 2009
2 answers
155 views
Hi guys,

Is there a way to Persist RadScheduler Appointments to a file or something ( Serialization).

I don't want to create a schema for the appoitments in the DB or putting them in an XML schema storage.

Any built-in Serialization for it?

Thanks.


Joseph
Top achievements
Rank 1
 answered on 16 Nov 2009
1 answer
98 views
I'd like to implement my own version of a popup when the user mouses over an appointment on the schedule control.  I've tried adding it to the attributes collection on both the Appointment object and the AppointmentControl object, but neither of these has worked.  Is there a way to add this attribute to appointments?
Peter
Telerik team
 answered on 16 Nov 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?