Telerik Forums
UI for ASP.NET AJAX Forum
5 answers
212 views
When clicking on the "more..." link on the RadScheduler I receive the following error:

The DateTime represented by the string is not supported in calendar System.Globalization.GregorianCalendar.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.FormatException: The DateTime represented by the string is not supported in calendar System.Globalization.GregorianCalendar.


Exception information:
    Exception type: FormatException
    Exception message: The DateTime represented by the string is not supported in calendar System.Globalization.GregorianCalendar.
   at System.DateTimeParse.ParseExact(String s, String format, DateTimeFormatInfo dtfi, DateTimeStyles style)
   at System.DateTime.ParseExact(String s, String format, IFormatProvider provider, DateTimeStyles style)
   at Telerik.Web.UI.SchedulerPostBackEvent.ParseJavaScriptTime(String jsTime)
   at Telerik.Web.UI.SchedulerPostBackEvent.DeserializeFromJSON(String json, RadScheduler scheduler)
   at Telerik.Web.UI.RadScheduler.RaisePostBackEvent(String eventArgument)
   at Telerik.Web.UI.RadScheduler.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument)
   at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
   at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

I do not get a line number so I'm not sure where the conversion is being made.  Any help would be appreciated.

This is my Master Page:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="MacroTesting.aspx.cs" Inherits="corCalendarSpecialEvents.MacroTesting" %>
 
<%@ Register src="usercontrols/corCalendarSpecialEvents.ascx" tagname="corCalendarSpecialEvents" tagprefix="uc1" %>
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <asp:ScriptManager ID="ScriptManager1" runat="server" EnableScriptGlobalization="true">
    </asp:ScriptManager>
     
    <div>
        <uc1:corCalendarSpecialEvents ID="corCalendarSpecialEvents1" runat="server" />      
    </div>
    </form>
</body>
</html>

Here is the ASCX:
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="corCalendarSpecialEvents.ascx.cs" Inherits="corCalendarSpecialEvents.usercontrols.corCalendarSpecialEvents" %>
<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %>
<script type="text/javascript" src="http://www.site.com/Scripts/corCalendarEvent.js"></script>
<script type="text/javascript">
    function DisplayEventDetails(sender, eventArgs) {
 
        var IE = navigator.userAgent;
        if (IE.match("MSIE")) {
            var apt = eventArgs.get_appointment();
            var IE = navigator.userAgent;
            var startDate = new Date();
            var endDate = new Date();
            startDate = apt.get_start();
            endDate = apt.get_end();
 
            startDate = dateFormat(startDate, "dddd, mmmm, dS, yyyy, hh:MM:ss TT");
            endDate = dateFormat(endDate, "dddd, mmmm, dS, yyyy, hh:MM:ss TT");
 
            alert("Event:  " + apt.get_subject() + "\n" + "Description:  " + apt.get_description() + "\n" + "Start:  " + startDate.toString() + " CST" + "\n" + "End:  " + endDate.toString() + " CST");
        }
 
        else {
            var oWnd = $find("<%=corEventWindow.ClientID %>");
            var apt = eventArgs.get_appointment();
 
            subject = apt.get_subject();
            description = apt.get_description();
            start = apt.get_start();
            end = apt.get_end();
 
            start = dateFormat(start, "dddd, mmmm, dS, yyyy, hh:MM:ss TT");
            end = dateFormat(end, "dddd, mmmm, dS, yyyy, hh:MM:ss TT");
 
            document.getElementById("corEventText").innerHTML = subject;
            document.getElementById("corEventDescription").innerHTML = description;
            document.getElementById("corEventStart").innerHTML = start.toString() + " CST";
            document.getElementById("corEventEnd").innerHTML = end.toString() + " CST";
 
            oWnd.show();
        }
    }
</script>
 
<telerik:RadScheduler ID="rsCorSECalendar" runat="server"
    DataDescriptionField="Description" DataEndField="End" DataKeyField="ID"
    DataRecurrenceField="RecurrenceRule" DataRecurrenceParentKeyField="RecurrenceParentID" DataReminderField="Reminder"
    DataSourceID="corSPCalendar" DataStartField="Start" DataSubjectField="Subject"
    StartEditingInAdvancedForm="False" EnableDescriptionField="True" SelectedView="MonthView"
    Width="794px" ReadOnly="true" Height="575px" OnClientAppointmentClick="DisplayEventDetails"
    Skin="Telerik" AdvancedForm-Modal="true" Culture="en-US">
        <AppointmentTemplate>
            <div id="corSEApptTemplate" style="font-family:Calibri;font-size:10pt;">
                <span style="font-weight:bold">Event: </span><%# Eval("Subject") %>
                <br />
                <span style="font-weight:bold">Description: </span><%# Eval("Description") %>
                <br />
                <span style="font-weight:bold">Start Time: </span><%# Eval("Start") %>
                      
                <span style="font-weight:bold">End Time: </span><%# Eval("End") %>
            </div>
        </AppointmentTemplate>
</telerik:RadScheduler>
<asp:SqlDataSource ID="corSPCalendar" runat="server"
    ConflictDetection="CompareAllValues"
    ConnectionString="<%$ ConnectionStrings:corCalendarSpecialEvents %>"
    DeleteCommand="DELETE FROM [Appointments] WHERE [ID] = @original_ID AND [Subject] = @original_Subject AND (([Description] = @original_Description) OR ([Description] IS NULL AND @original_Description IS NULL)) AND [Start] = @original_Start AND [End] = @original_End AND (([RoomID] = @original_RoomID) OR ([RoomID] IS NULL AND @original_RoomID IS NULL)) AND (([UserID] = @original_UserID) OR ([UserID] IS NULL AND @original_UserID IS NULL)) AND (([RecurrenceRule] = @original_RecurrenceRule) OR ([RecurrenceRule] IS NULL AND @original_RecurrenceRule IS NULL)) AND (([RecurrenceParentID] = @original_RecurrenceParentID) OR ([RecurrenceParentID] IS NULL AND @original_RecurrenceParentID IS NULL)) AND (([Reminder] = @original_Reminder) OR ([Reminder] IS NULL AND @original_Reminder IS NULL)) AND (([Annotations] = @original_Annotations) OR ([Annotations] IS NULL AND @original_Annotations IS NULL))"
    InsertCommand="INSERT INTO [Appointments] ([Subject], [Description], [Start], [End], [RoomID], [UserID], [RecurrenceRule], [RecurrenceParentID], [Reminder], [Annotations]) VALUES (@Subject, @Description, @Start, @End, @RoomID, @UserID, @RecurrenceRule, @RecurrenceParentID, @Reminder, @Annotations)"
    OldValuesParameterFormatString="original_{0}"
    SelectCommand="SELECT * FROM [Appointments]"
    UpdateCommand="UPDATE [Appointments] SET [Subject] = @Subject, [Description] = @Description, [Start] = @Start, [End] = @End, [RoomID] = @RoomID, [UserID] = @UserID, [RecurrenceRule] = @RecurrenceRule, [RecurrenceParentID] = @RecurrenceParentID, [Reminder] = @Reminder, [Annotations] = @Annotations WHERE [ID] = @original_ID AND [Subject] = @original_Subject AND (([Description] = @original_Description) OR ([Description] IS NULL AND @original_Description IS NULL)) AND [Start] = @original_Start AND [End] = @original_End AND (([RoomID] = @original_RoomID) OR ([RoomID] IS NULL AND @original_RoomID IS NULL)) AND (([UserID] = @original_UserID) OR ([UserID] IS NULL AND @original_UserID IS NULL)) AND (([RecurrenceRule] = @original_RecurrenceRule) OR ([RecurrenceRule] IS NULL AND @original_RecurrenceRule IS NULL)) AND (([RecurrenceParentID] = @original_RecurrenceParentID) OR ([RecurrenceParentID] IS NULL AND @original_RecurrenceParentID IS NULL)) AND (([Reminder] = @original_Reminder) OR ([Reminder] IS NULL AND @original_Reminder IS NULL)) AND (([Annotations] = @original_Annotations) OR ([Annotations] IS NULL AND @original_Annotations IS NULL))">
    <DeleteParameters>
        <asp:Parameter Name="original_ID" Type="Int32" />
        <asp:Parameter Name="original_Subject" Type="String" />
        <asp:Parameter Name="original_Description" Type="String" />
        <asp:Parameter Name="original_Start" Type="DateTime" />
        <asp:Parameter Name="original_End" Type="DateTime" />
        <asp:Parameter Name="original_RoomID" Type="Int32" />
        <asp:Parameter Name="original_UserID" Type="Int32" />
        <asp:Parameter Name="original_RecurrenceRule" Type="String" />
        <asp:Parameter Name="original_RecurrenceParentID" Type="Int32" />
        <asp:Parameter Name="original_Reminder" Type="String" />
        <asp:Parameter Name="original_Annotations" Type="String" />
    </DeleteParameters>
    <InsertParameters>
        <asp:Parameter Name="Subject" Type="String" />
        <asp:Parameter Name="Description" Type="String" />
        <asp:Parameter Name="Start" Type="DateTime" />
        <asp:Parameter Name="End" Type="DateTime" />
        <asp:Parameter Name="RoomID" Type="Int32" />
        <asp:Parameter Name="UserID" Type="Int32" />
        <asp:Parameter Name="RecurrenceRule" Type="String" />
        <asp:Parameter Name="RecurrenceParentID" Type="Int32" />
        <asp:Parameter Name="Reminder" Type="String" />
        <asp:Parameter Name="Annotations" Type="String" />
    </InsertParameters>
    <UpdateParameters>
        <asp:Parameter Name="Subject" Type="String" />
        <asp:Parameter Name="Description" Type="String" />
        <asp:Parameter Name="Start" Type="DateTime" />
        <asp:Parameter Name="End" Type="DateTime" />
        <asp:Parameter Name="RoomID" Type="Int32" />
        <asp:Parameter Name="UserID" Type="Int32" />
        <asp:Parameter Name="RecurrenceRule" Type="String" />
        <asp:Parameter Name="RecurrenceParentID" Type="Int32" />
        <asp:Parameter Name="Reminder" Type="String" />
        <asp:Parameter Name="Annotations" Type="String" />
        <asp:Parameter Name="original_ID" Type="Int32" />
        <asp:Parameter Name="original_Subject" Type="String" />
        <asp:Parameter Name="original_Description" Type="String" />
        <asp:Parameter Name="original_Start" Type="DateTime" />
        <asp:Parameter Name="original_End" Type="DateTime" />
        <asp:Parameter Name="original_RoomID" Type="Int32" />
        <asp:Parameter Name="original_UserID" Type="Int32" />
        <asp:Parameter Name="original_RecurrenceRule" Type="String" />
        <asp:Parameter Name="original_RecurrenceParentID" Type="Int32" />
        <asp:Parameter Name="original_Reminder" Type="String" />
        <asp:Parameter Name="original_Annotations" Type="String" />
    </UpdateParameters>
</asp:SqlDataSource>
<telerik:RadWindowManager ID="rwmSECalendar" AutoSize="false" KeepInScreenBounds="true"
    runat="server">
    <Windows>
        <telerik:RadWindow ID="corEventWindow" runat="server" Title="Event Details" IconUrl="http://www.rockfordil.gov/media/view_calendar_tasks.png"
            VisibleOnPageLoad="false" Width="560px" Height="350px" Skin="Telerik" Modal="true">
            <ContentTemplate>
                <div id="corEvent" class="corEvent">
                    <p style="padding-left: 10px; padding-right:10px;">                   
                        <span style="font-family:Calibri,Trebuchet MS, Arial; font-size: 20pt; font-weight:bold;">Event:</span>   <span id="corEventText" style="font-family:Calibri,Trebuchet MS, Arial; font-size: 14pt;"></span>
                        <br />
                        <br />
                        <span style="font-family:Calibri,Trebuchet MS, Arial; font-size: 20pt; font-weight:bold;">Description:</span>   <span id="corEventDescription" style="font-family:Calibri,Trebuchet MS, Arial; font-size: 14pt;"></span>
                        <br />
                        <br />
                        <span style="font-family:Calibri,Trebuchet MS, Arial; font-size: 20pt; font-weight:bold;">Start:</span>   <span id="corEventStart" style="font-family:Calibri,Trebuchet MS, Arial; font-size: 14pt;"></span>
                        <br />
                        <br />
                        <span style="font-family:Calibri,Trebuchet MS, Arial; font-size: 20pt; font-weight:bold;">End:</span>   <span id="corEventEnd" style="font-family:Calibri,Trebuchet MS, Arial; font-size: 14pt;"></span>
                    </p>
                </div>
            </ContentTemplate>
        </telerik:RadWindow>
    </Windows>
</telerik:RadWindowManager>
corCalendarEvent.js
var dateFormat = function () {
    var token = /d{1,4}|m{1,4}|yy(?:yy)?|([HhMsTt])\1?|[LloSZ]|"[^"]*"|'[^']*'/g,
    timezone = /\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g,
    timezoneClip = /[^-+\dA-Z]/g,
    pad = function (val, len) {
        val = String(val);
        len = len || 2;
        while (val.length < len) val = "0" + val;
        return val;
    };
 
    // Regexes and supporting functions are cached through closure
    return function (date, mask, utc) {
        var dF = dateFormat;
 
        // You can't provide utc if you skip other args (use the "UTC:" mask prefix)
        if (arguments.length == 1 && Object.prototype.toString.call(date) == "[object String]" && !/\d/.test(date)) {
            mask = date;
            date = undefined;
        }
 
        // Passing date through Date applies Date.parse, if necessary
        date = date ? new Date(date) : new Date;
        if (isNaN(date)) throw SyntaxError("invalid date");
 
        mask = String(dF.masks[mask] || mask || dF.masks["default"]);
 
        // Allow setting the utc argument via the mask
        if (mask.slice(0, 4) == "UTC:") {
            mask = mask.slice(4);
            utc = true;
        }
 
        var _ = utc ? "getUTC" : "get",
        d = date[_ + "Date"](),
        D = date[_ + "Day"](),
        m = date[_ + "Month"](),
        y = date[_ + "FullYear"](),
        H = date[_ + "Hours"](),
        M = date[_ + "Minutes"](),
        s = date[_ + "Seconds"](),
        L = date[_ + "Milliseconds"](),
        o = utc ? 0 : date.getTimezoneOffset(),
        flags = {
            d: d,
            dd: pad(d),
            ddd: dF.i18n.dayNames[D],
            dddd: dF.i18n.dayNames[D + 7],
            m: m + 1,
            mm: pad(m + 1),
            mmm: dF.i18n.monthNames[m],
            mmmm: dF.i18n.monthNames[m + 12],
            yy: String(y).slice(2),
            yyyy: y,
            h: H % 12 || 12,
            hh: pad(H % 12 || 12),
            H: H,
            HH: pad(H),
            M: M,
            MM: pad(M),
            s: s,
            ss: pad(s),
            l: pad(L, 3),
            L: pad(L > 99 ? Math.round(L / 10) : L),
            t: H < 12 ? "a" : "p",
            tt: H < 12 ? "am" : "pm",
            T: H < 12 ? "A" : "P",
            TT: H < 12 ? "AM" : "PM",
            Z: utc ? "UTC" : (String(date).match(timezone) || [""]).pop().replace(timezoneClip, ""),
            o: (o > 0 ? "-" : "+") + pad(Math.floor(Math.abs(o) / 60) * 100 + Math.abs(o) % 60, 4),
            S: ["th", "st", "nd", "rd"][d % 10 > 3 ? 0 : (d % 100 - d % 10 != 10) * d % 10]
        };
 
        return mask.replace(token, function ($0) {
            return $0 in flags ? flags[$0] : $0.slice(1, $0.length - 1);
        });
    };
} ();
 
// Some common format strings
dateFormat.masks = {
    "default": "ddd mmm dd yyyy HH:MM:ss",
    shortDate: "m/d/yy",
    mediumDate: "mmm d, yyyy",
    longDate: "mmmm d, yyyy",
    fullDate: "dddd, mmmm d, yyyy",
    shortTime: "h:MM TT",
    mediumTime: "h:MM:ss TT",
    longTime: "h:MM:ss TT Z",
    isoDate: "yyyy-mm-dd",
    isoTime: "HH:MM:ss",
    isoDateTime: "yyyy-mm-dd'T'HH:MM:ss",
    isoUtcDateTime: "UTC:yyyy-mm-dd'T'HH:MM:ss'Z'"
};
 
// Internationalization strings
dateFormat.i18n = {
    dayNames: [
    "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat",
    "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"
  ],
    monthNames: [
    "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec",
    "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"
  ]
};
 
// For convenience...
Date.prototype.format = function (mask, utc) {
    return dateFormat(this, mask, utc);
};
Boyan Dimitrov
Telerik team
 answered on 19 Feb 2013
2 answers
208 views
Hi All,

I have a RadFileExplorer in my project which displays a list of Images in a directory. I want the location eg.\WebSphere\Spec02\Images to be hidden from the fileexplorer and also prevent opening the image files directly in the window.

Any help appreciated,
JC 
Dobromir
Telerik team
 answered on 19 Feb 2013
2 answers
121 views

if any possible do function like crystal report like in Telerik report


Thanks Advance,
Mohamed.
mohamed
Top achievements
Rank 1
 answered on 19 Feb 2013
2 answers
113 views
Hi,

I am openning a radwindow on button click from code behind as below in silverlight 5 app:

 RadWindow newChldWindow = newRadWindow();
            newChldWindow.Closed += popUpCloseEvent;
            newChldWindow.Height = 650;
            newChldWindow.Width = 1000;
            newChldWindow.ResizeMode = ResizeMode.CanResize;
            newChldWindow.CanMove = true;

Would it be possible to add print functionality to this from code behind?

Thanks
Sam
Top achievements
Rank 1
 answered on 19 Feb 2013
1 answer
97 views
Hi,

I am using the Telerik Radtreeview with the checkbox nodes, which works fine until i implement the RadAjaxManager
to enable the export functions on the grid, then i am unable to click the checkboxes, but space ticks them? I generate
the Nodes Dynamically.

Heres a sample of my RadAjaxManager:
<telerik:RadAjaxManager ID="RadAjaxManager2" runat="server">
                <ClientEvents OnRequestStart="onRequestStart"></ClientEvents>
                <AjaxSettings>
                    <telerik:AjaxSetting AjaxControlID="grdUsers">
                        <UpdatedControls>
                            <telerik:AjaxUpdatedControl ControlID="grdUsers"></telerik:AjaxUpdatedControl>
                        </UpdatedControls>
                    </telerik:AjaxSetting>
                </AjaxSettings>
            </telerik:RadAjaxManager>

 

 

 

 

 


Any idea on how to fix this?

Kate
Telerik team
 answered on 19 Feb 2013
2 answers
72 views
Hi,
I am using Radeditor with EditorDropDown on toolbar. I need to bind data to the EditorDropDown client side or using web method,  if there any option for add  Clinet events for EditorDropDown.  I need a quick reply.






Thanks





Dhamodharan
Top achievements
Rank 1
 answered on 19 Feb 2013
1 answer
95 views
Hi All,
I'm having trouble with Form Validation when using the MetroTouch skin. I'm using a mix of RequiredFieldValidator/RequiredExpressionValidator controls for my RadTextBox's on a simple registration page. On all the other skins if a user enters text that doesn't meet the validation criteria the error is displayed immediately to the right hand side of the RadTextBox.

However, with the MetroTouch skin nothing is displayed until the RadButton is hit to postback. Also, when you fix something unless you click on another control the error does not go away.

I can reproduce this behaviour on all skins by simply adding this to the style sheet as well:

body

{

font-size:smaller;

}

 


I'll post my code here so you can test. You shouldn't need the style sheet as the functionality remains broken without it.
Register.aspx
<head runat="server">
    <title></title>
 
    <link rel="stylesheet" type="text/css" href="styles.css"/>
</head>
<body>
    <form id="form1" runat="server">  
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server"></telerik:RadScriptManager>
    <telerik:RadSkinManager ID="RadSkinManager1" runat="server" Skin="Hay" ShowChooser="True"></telerik:RadSkinManager>
    <telerik:RadFormDecorator runat="server" ID="RadFormDecorator1" DecoratedControls="All"></telerik:RadFormDecorator>
 
    <div class="exampleWrapper">
        <telerik:RadTabStrip ID="RadTabStrip1" runat="server" SelectedIndex="0" MultiPageID="RadMultiPage1" >
            <Tabs>
                <telerik:RadTab runat="server" Selected="True" Text="Registration" PageViewID="Registration">
                </telerik:RadTab>
                <telerik:RadTab runat="server" Text="How it works" PageViewID="HowitWorks">
                </telerik:RadTab>
                <telerik:RadTab runat="server" Text="Prizes" PageViewID="Prizes">
                </telerik:RadTab>
            </Tabs>
        </telerik:RadTabStrip>
        <telerik:RadMultiPage ID="RadMultiPage1" runat="server" SelectedIndex="0" CssClass="multiPage">
 
            <telerik:RadPageView ID="Registration" runat="server">                          
                 <br />
                 <telerik:RadTextBox runat="server" ID="Email" Label="Email:" Width="400px" ></telerik:RadTextBox>
                 <asp:RegularExpressionValidator ID="emailValidator" ValidationGroup="Registration" runat="server" Display="Dynamic" ErrorMessage="Please, enter valid e-mail address." ValidationExpression="^[\w\.\-]+@[a-zA-Z0-9\-]+(\.[a-zA-Z0-9\-]{1,})*(\.[a-zA-Z]{2,3}){1,2}$" ControlToValidate="Email" CssClass="RegularExpressionValidator"></asp:RegularExpressionValidator>
                 <asp:RequiredFieldValidator ID="TextBoxRequiredFieldValidator" ValidationGroup="Registration" runat="server" Display="Dynamic" ControlToValidate="Email" ErrorMessage="Please enter a valid email address!" CssClass="RegularExpressionValidator"></asp:RequiredFieldValidator>
                 <br /><br />
                 <telerik:RadTextBox runat="server" ID="Password" Label="Password:" Width="400px" TextMode="Password"></telerik:RadTextBox>
                 <br /><br />
                 <telerik:RadTextBox runat="server" ID="ConfirmPassword" Label="Confirm Password:" Width="400px" TextMode="Password"></telerik:RadTextBox>
                 <asp:CompareValidator ID="valCompPassword" runat="server" ValidationGroup="Registration" ControlToValidate="ConfirmPassword" ControlToCompare="Password" Display="Dynamic" ErrorMessage="Please make sure your passwords match!" CssClass="RegularExpressionValidator" />
                 <br /><br />
                 <telerik:RadTextBox runat="server" ID="Firstname" Label="First name:" Width="400px"></telerik:RadTextBox>
                 <asp:RequiredFieldValidator ID="RequiredFieldValidator1" ValidationGroup="Registration" runat="server" Display="Dynamic" ControlToValidate="Firstname" ErrorMessage="Please enter your first name!" CssClass="RegularExpressionValidator"></asp:RequiredFieldValidator>
                 <br /><br />
                 <telerik:RadTextBox runat="server" ID="Surname" Label="Surname:" Width="400px"></telerik:RadTextBox>
                 <asp:RequiredFieldValidator ID="RequiredFieldValidator2" ValidationGroup="Registration" runat="server" Display="Dynamic" ControlToValidate="Surname" ErrorMessage="Please enter your surname!" CssClass="RegularExpressionValidator"></asp:RequiredFieldValidator>
                 <br /><br />
                 <telerik:RadMaskedTextBox runat="server" ID="PhoneNumber" Label="Mobile number:" Width="400px" Mask="####-###-###"></telerik:RadMaskedTextBox>
                 <asp:RequiredFieldValidator ID="RequiredFieldValidator3" ValidationGroup="Registration" runat="server" Display="Dynamic" ControlToValidate="PhoneNumber" ErrorMessage="Please enter your mobile number!" CssClass="RegularExpressionValidator"></asp:RequiredFieldValidator>
                 <asp:RegularExpressionValidator ID="RegularExpressionValidator1" ValidationGroup="Registration" runat="server" Display="Dynamic" ErrorMessage="Please enter valid mobile number." ValidationExpression="^[0]\d{3}-\d{3}-\d{3}$" ControlToValidate="PhoneNumber" CssClass="RegularExpressionValidator"></asp:RegularExpressionValidator>
                 <br /><br />
                 <telerik:RadMaskedTextBox runat="server" ID="AlternatePhoneNumber" Label="Alternate number:" Width="400px" Mask="####-###-###"></telerik:RadMaskedTextBox>                
                 <br /><br />
                 <telerik:RadTextBox runat="server" ID="Address" Label="Street Address:" Width="400px"></telerik:RadTextBox>
                 <asp:RequiredFieldValidator ID="RequiredFieldValidator4" ValidationGroup="Registration" runat="server" Display="Dynamic" ControlToValidate="Address" ErrorMessage="Please enter your address!" CssClass="RegularExpressionValidator"></asp:RequiredFieldValidator>
                 <br /><br />
                 <telerik:RadTextBox runat="server" ID="City" Label="City/Suburb:" Width="400px"></telerik:RadTextBox>
                 <asp:RequiredFieldValidator ID="RequiredFieldValidator5" ValidationGroup="Registration" runat="server" Display="Dynamic" ControlToValidate="City" ErrorMessage="Please enter your city/suburb!" CssClass="RegularExpressionValidator"></asp:RequiredFieldValidator>
                 <br /><br />
                 <telerik:RadTextBox runat="server" ID="Country" Label="Country:" Width="400px"></telerik:RadTextBox>
                 <asp:RequiredFieldValidator ID="RequiredFieldValidator6" ValidationGroup="Registration" runat="server" Display="Dynamic" ControlToValidate="Country" ErrorMessage="Please enter your country!" CssClass="RegularExpressionValidator" InitialValue="Australia"></asp:RequiredFieldValidator>
                 <br /><br />
                 <telerik:RadTextBox runat="server" ID="PostCode" Label="Post Code:" Width="400px"></telerik:RadTextBox>
                 <asp:RequiredFieldValidator ID="RequiredFieldValidator7" ValidationGroup="Registration" runat="server" Display="Dynamic" ControlToValidate="PostCode" ErrorMessage="Please enter your post code!" CssClass="RegularExpressionValidator" InitialValue="Australia"></asp:RequiredFieldValidator>
                 <br /><br />
                 <telerik:RadButton ID="btnRegister" runat="server" Text="Register Now" ValidationGroup="Registration" ButtonType="StandardButton" BackColor="#F9F9F9"></telerik:RadButton>
                 <p></p>
            </telerik:RadPageView>
 
            <telerik:RadPageView ID="HowItWorks" runat="server" ForeColor="White">
                <p>HowItWorks</p>
            </telerik:RadPageView>
            <telerik:RadPageView ID="Prizes" runat="server">
                <p>Prizes</p>
            </telerik:RadPageView>
        </telerik:RadMultiPage>       
    </div>
    </form>
</body>
</html>
Vasil
Telerik team
 answered on 19 Feb 2013
3 answers
280 views
I have a page where I have a number of sitemap controls.  Each one may have a different background color.  For some of the sitemaps, I can use the default font, color, background hover color, etc.  For the others, I need to change different attributes.  I tried using the CssClass to override the color as well as the ForeColor attribute on the control and the nodes but alas, it did not work.  I know I can override the group css class, but that's not an option as far as I can see, it would override all of my sitemap controls.

Please advise if there is a solution to my issue.  I can supply a screenshot if that is helpful to understanding what I am trying to accomplish.
Kate
Telerik team
 answered on 19 Feb 2013
3 answers
104 views

I have  a GridTemplateColumn bind to “State” data field and the values are fixed or Enum type:

<telerik:GridTemplateColumn DataField="State" DataType="System.Byte" DefaultInsertValue="1"

    UniqueName="StateColumn" GroupByExpression="State Group By State">

    <EditItemTemplate>

        <telerik:RadComboBox ID="StateRadComboBox" runat="server"

SelectedValue='<%#Bind("State")%>'>

            <Items>

                <telerik:RadComboBoxItem runat="server" Text="Active" Value="1" />

                <telerik:RadComboBoxItem runat="server" Text="Inactive" Value="2" />

                <telerik:RadComboBoxItem runat="server" Text="Erased" Value="3" />

                <telerik:RadComboBoxItem runat="server" Text="Pendent" Value="4" />

            </Items>

        </telerik:RadComboBox>

    </EditItemTemplate>

    <ItemTemplate>

        <asp:Label ID="StateLabel" runat="server"

Text='<%# … a logic to get text based on numeric value '></asp:Label>

    </ItemTemplate>

</telerik:GridTemplateColumn>

When forms a group show the numerical value (State: 1, State: 2, State: 3 or State: 4). How can I show your description instead of the numerical value (State: Active, State: Inactive, State: Erased or State: Pendent)?

 

I have the same problem when use GridDropDownColumn and ObjectDataSource:

<telerik:GridDropDownColumn DataField="State" DataSourceID="StateObjectDataSource"

    ListTextField="TextValue" ListValueField="ByteValue" UniqueName="StateColumn"

    DataType="System.Byte">

</telerik:GridDropDownColumn>

Any help?
Kostadin
Telerik team
 answered on 19 Feb 2013
1 answer
48 views
Hi I have two date selectors using the RadDate control I would like to set the first date selector to be from today and not allow previous dates to be selected the second date control should only allow dates from the date selected in the first date box onward 

datebox 1 date = 21/02/2013
datebox 2 date => 21/02/2013 or later 
with 
<telerik:RadDatePicker ID="dpRequired1" runat="server" SelectedDate='<%# Bind("Required") %>'></telerik:RadDatePicker>

any suggestions thanks
Vasil
Telerik team
 answered on 19 Feb 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?