Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
379 views
hi all
I have 3 level Rad grid hierarchy.
I want each detail table has specific header backcolor.how can I do that?
Mohamed Yasin
Top achievements
Rank 1
 answered on 24 Jul 2013
1 answer
98 views
Hi Team and Dear all,

I have ready to creat web applications using Control Telerik.

When I not use Telerik Control in Page Login after published in IIS.
I call my web in URL ,: http://localhost:8080/
event button click is Fine and Work call code behind Process..

but, when I using Control Telerik,like RadScriptmanager and others...
when I click button Login,that not work...
When I call URL this "http://localhost:8080/" it's no work, but when I add specific page like " http://localhost:8080/default.aspx" ,it;'s work..

in IE,Firefox and GoogleChome it's not Work....

this, my code, my be i was wrong something or anything else...
please help me..
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="eRTE.Default" %>
<!DOCTYPE html>
 
<head runat="server">
    <title>eRTE</title>
    <link href="~/Content/Site.css" rel="stylesheet" />
</head>
<body>
    <form id="form1" runat="server">
         
         
    <div>
    <asp:ScriptManager runat="server" ID="ScriptManager1"></asp:ScriptManager>
        <telerik:RadStyleSheetManager ID="RadStyleSheetManager1" runat="server">
        </telerik:RadStyleSheetManager>
        <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        </telerik:RadAjaxManager>
        <telerik:RadWindowManager ID="RadWindowManager1" runat="server" Skin="Metro">
        </telerik:RadWindowManager>
     
    </div>
    <div style="height: 175px">
     
    </div>
 
        <div style="height: 150px">
            <table style="width: 100%">
                <tr>
                    <td align="center" colspan="3">
                        <img alt="logo" src="Images/logosystem.png" />
                    </td>
                </tr>
                <tr>
                    <td style="width: 40%"></td>
                    <td>
                        <table style="width: 100%">
                            <tr><td>
                                    <span style="font-size: 13px;color: #666;">USERNAME</span>
                                </td><td><span style="font-size: 13px;color: #666;">PASSWORD</span>
                                     </td></tr>
                            <tr><td>
                                         <telerik:RadTextBox runat="server" ID="tbusername" AutoCompleteType="Disabled"></telerik:RadTextBox>
                                </td><td>
                                         <telerik:RadTextBox runat="server" ID="tbpass" TextMode="Password" AutoCompleteType="Disabled"></telerik:RadTextBox>
                                     </td></tr>
                            <tr><td>
                                    <asp:Button Text="Login" ID="btnLogin" runat="server" CssClass="buttonsubmit" Width="75px" OnClick="btnLogin_Click"/>                                </td><td></td></tr>
                        </table>
                         
                    </td>
                    <td style="width: 35%"></td>
                </tr>
                <tr>
                    <td style="width: 40%"> </td>
                    <td>
                             <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="tbusername" CssClass="field-validation-error" ErrorMessage="The user name field is required." /><br />
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="tbpass" CssClass="field-validation-error" ErrorMessage="The password field is required." />
     
                    </td>
                    <td style="width: 35%"> </td>
                </tr>
            </table>
 
        </div>
        <div style="height: 250px"></div>
        <div style="text-align: center; color: #333;font-size: 12px;" >
Copyright ©  <%: DateTime.Now.Year.ToString() %>· All rights reserved.
        </div>
    </form>
</body>
</html>

and this code behind

using System;
using System.Collections.Generic;
using System.Configuration;
using System.Globalization;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
 
namespace eRTE
{
    public partial class Default : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            Form.DefaultButton = btnLogin.ClientID;
            Form.DefaultFocus = tbusername.UniqueID;
            if (!IsPostBack && (Request.Cookies["__LOGINCOOKIE__"] == null || Request.Cookies["__LOGINCOOKIE__"].Value == ""))
            {
 
                Session.Abandon();
                Response.Cookies.Add(new HttpCookie("ASP.NET_SessionId", ""));
            }
 
 
 
        }
 
        private void AddRedirCookie(string userdata)
        {
        }
 
        protected void btnLogin_Click(object sender, EventArgs e)
        {
 
           //this my code process event login,
          // when I using control telerik, can't  proses to this event...why..???
        }
 
 
    }
}

trims a lot,

best reagrds,

chester
BabaYa
Top achievements
Rank 1
 answered on 24 Jul 2013
1 answer
184 views
I have a screen that has a Radgrid.  The radgrid uses a user control for the edit form.  When the edit button is pressed on the grid it loades the user control.  The User control is just a series of textboxes that are bound to the data from the grid.
<asp:TextBox ID="FamilyID" runat="server" value='<%# DataBinder.Eval(Container, "DataItem.FamilyID") %>'></asp:TextBox>

On the load event of this control there are a series of buttons that I want to make visible depending on the values in the text boxes.  The ossue I am having is since the values are set with DataBinder.Eval they do not have a value on the page_Load event.  How do I get the values so I can alter the screen?



Jayesh Goyani
Top achievements
Rank 2
 answered on 24 Jul 2013
2 answers
113 views
Hi,

I cannot fix this issue about missing resource value. On the radScheduler it shows Telerik.Web.UI.Resource instead of the value. Any ideas? thank you.
here is the code:

<telerik:RadScheduler ID="RadScheduler1"
    CustomAttributeNames="EndTime,StartTime" CssClass="testing" OnClientAppointmentResizing="pereventResize"
    OnClientAppointmentMoveStart="PreventDragDrop" runat="server" DataEndField="EndTime"
    DataKeyField="Id" DataSourceID="SqlDataSource1" DataStartField="StartTime" DataSubjectField="Subject"
    Height="" Skin="Office2010Blue" StartEditingInAdvancedForm="False" DayEndTime="20:00:00"
    DayStartTime="09:00:00" FirstDayOfWeek="Monday" LastDayOfWeek="Sunday" OnAppointmentInsert="RadScheduler1_AppointmentInsert"
    OnAppointmentUpdate="RadScheduler1_AppointmentUpdate" WorkDayEndTime="20:00:00"
    WorkDayStartTime="09:00:00" AllowDelete="False" DataDescriptionField="Description"
    DataRecurrenceField="RecData" DataRecurrenceParentKeyField="RecParrent"
    EnableDescriptionField="True">
    <ResourceTypes>
        <telerik:ResourceType DataSourceID="SqlDataSource2"
            ForeignKeyField="MeetingRoomID" KeyField="ID" Name="Floor"
            TextField="MeetingRoomFloor" />
    </ResourceTypes>
    <AppointmentTemplate>
        <div>
            <h2>
                <%#Eval("Subject") %>
            </h2>
            <p>
                <%#Eval("Description") %></p>   <%#Eval("Floor") %>
                 
        </div>
    </AppointmentTemplate>
</telerik:RadScheduler>
<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:CompanyInfoEventsConnectionString %>"
    DeleteCommand="DELETE FROM [Event] WHERE [Id] = @Id" InsertCommand="INSERT INTO [Event] ([Subject], [StartTime], [EndTime], [Description], [RecParrent], [RecData], [MeetingRoomID]) VALUES (@Subject, @StartTime, @EndTime, @Description, @RecParrent, @RecData, @MeetingRoomID)"
    SelectCommand="SELECT * FROM [Event]"
     
    UpdateCommand="UPDATE [Event] SET [Subject] = @Subject, [StartTime] = @StartTime, [EndTime] = @EndTime, [Description] = @Description, [RecParrent] = @RecParrent, [RecData] = @RecData, [MeetingRoomID] = @MeetingRoomID WHERE [Id] = @Id">
    <DeleteParameters>
        <asp:Parameter Name="Id" Type="Int32" />
    </DeleteParameters>
    <InsertParameters>
        <asp:Parameter Name="Subject" Type="String" />
        <asp:Parameter Name="StartTime" Type="DateTime" />
        <asp:Parameter Name="EndTime" Type="DateTime" />
        <asp:Parameter Name="Description" Type="String" />
        <asp:Parameter Name="RecParrent" Type="Int32" />
        <asp:Parameter Name="RecData" Type="String" />
        <asp:Parameter Name="MeetingRoomID" Type="Int32" />
    </InsertParameters>
    <UpdateParameters>
        <asp:Parameter Name="Subject" Type="String" />
        <asp:Parameter Name="StartTime" Type="DateTime" />
        <asp:Parameter Name="EndTime" Type="DateTime" />
        <asp:Parameter Name="Description" Type="String" />
        <asp:Parameter Name="RecParrent" Type="Int32" />
        <asp:Parameter Name="RecData" Type="String" />
        <asp:Parameter Name="MeetingRoomID" Type="Int32" />
        <asp:Parameter Name="Id" Type="Int32" />
    </UpdateParameters>
</asp:SqlDataSource>
 
<asp:SqlDataSource ID="SqlDataSource2" runat="server"
    ConnectionString="<%$ ConnectionStrings:CompanyInfoEventsConnectionString %>"
    DeleteCommand="DELETE FROM [MeetRoomFloor] WHERE [ID] = @ID"
    InsertCommand="INSERT INTO [MeetRoomFloor] ([MeetingRoomFloor]) VALUES (@MeetingRoomFloor)"
    SelectCommand="SELECT * FROM [MeetRoomFloor]"
    UpdateCommand="UPDATE [MeetRoomFloor] SET [MeetingRoomFloor] = @MeetingRoomFloor WHERE [ID] = @ID">
    <DeleteParameters>
        <asp:Parameter Name="ID" Type="Int32" />
    </DeleteParameters>
    <InsertParameters>
        <asp:Parameter Name="MeetingRoomFloor" Type="String" />
    </InsertParameters>
    <UpdateParameters>
        <asp:Parameter Name="MeetingRoomFloor" Type="String" />
        <asp:Parameter Name="ID" Type="Int32" />
    </UpdateParameters>
</asp:SqlDataSource>
Zura Chikhladze
Top achievements
Rank 1
 answered on 24 Jul 2013
11 answers
126 views
I am using Telerik ASPX / AJAX v.2011.3.1305.40

I have a page with a RadButton and an AsyncUpload (see aspx code below) a- along with other controls. If I first select a file using the AsyncUpload it will display the selected file (and waits until I click another button to actually do something with it). However, if I click btnClear, it clears the AsyncUpload control back to its original state. What do I need to do to prevent this from happening?

Thanks,
Andy

        <script type="text/javascript">
            function btnClear_Click( sender, eventArgs )
            {
                var ddl = $find( "<%= dropdownlist.ClientID %>" );
                ddl.set_text( "" );
                ddl.trackChanges();
                ddl.get_items().getItem( 0 ).set_text( "" );
                ddl.commitChanges();
                var tree = ddl.get_items().getItem( 0 ).findControl( "treeview" );
                var selectedNode = tree.get_selectedNode();
                if ( selectedNode != null )
                    selectedNode.set_selected( false );
            }
        </script>

             <telerik:RadButton ID="btnClear" runat="server" Text="" OnClientClicked="btnClear_Click"
                ToolTip="Clear setting">
                <Icon PrimaryIconCssClass="rbRemove" PrimaryIconLeft="4" PrimaryIconTop="4" />
            </telerik:RadButton>

           <div class="upload-panel">
                <h6>
                    1. Select .SEW file to import:</h6>
                <telerik:RadAsyncUpload ID="UploadControl" runat="server" MaxFileInputsCount="1"
                    AllowedFileExtensions="sew" />
            </div>

Bozhidar
Telerik team
 answered on 24 Jul 2013
7 answers
206 views
I want to set the control text but don't know how to get a hold of the control that is within a radgrid. Can someone help?
I have another thread related to this but it was mixed with insert form. I thought it'd be better to have a different thread for it.

Also, RadButton1_Click() is not even invoked if there is RequiredFieldValidator and the field value is empty. How can RequiredFieldValidator be disabled when the button is clicked so that it invokes RadButton1_Click() ?

<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<div>
  <telerik:RadButton runat="server" ID="RadButton1" AutoPostBack="true" Text="fill data"  ButtonType="LinkButton" onclick="RadButton1_Click"></telerik:RadButton>
</div>
  
<telerik:RadAjaxPanel runat=server>
    <telerik:RadGrid ID="RadGrid1" runat="server" AutoGenerateColumns="False"
            ShowStatusBar="True" GridLines="None"  OnNeedDataSource="RadGrid1_NeedDataSource"   OnUpdateCommand="RadGrid1_UpdateCommand"
            OnInsertCommand="RadGrid1_InsertCommand" OnCreateColumnEditor="RadGrid1_CreateColumnEditor"
            OnPreRender="RadGrid1_PreRender" OnItemDataBound="RadGrid1_ItemDataBound" OnItemCreated="RadGrid1_ItemCreated">
             
            <MasterTableView DataKeyNames="id" CommandItemDisplay="Top">
                <Columns>
                    <telerik:GridBoundColumn HeaderText="Emp" DataField="emp" UniqueName="emp">
  
 
protected void RadButton1_Click(object sender, EventArgs e)
{
        //set the text of emp to something else. How to get a hold of the control in here?
}
Jayesh Goyani
Top achievements
Rank 2
 answered on 24 Jul 2013
5 answers
234 views
Hi

When I select date from the raddatepicker, it is displayed in mm dd yy format in the date input. So how can I change the selected date format to dd mm yyyy format?

Thankyou
Needha
Shinu
Top achievements
Rank 2
 answered on 24 Jul 2013
13 answers
221 views
I am having a problem changing the RadScheduler view in Firefox.  In Internet Explorer I can change from Day to Week to Month to Timeline just fine.  In Firefox it only allows me to change the view once then it gets stuck on one view and will not let me switch views, I click the buttons but it wont do anything until i refresh the page and then it does the same thing all over.  Any ideas? 
Plamen
Telerik team
 answered on 24 Jul 2013
1 answer
208 views
Hi 

There are few input fields and required field validators and I tried to display the error message inside the control which is not completely possible due to browser related issues. So I thought of alerting the error messages on validation failed. But how can I get the error messages in javascript so that I can display them in an alert box? Is this a possible requirement?

Thanks
Ivy
Shinu
Top achievements
Rank 2
 answered on 24 Jul 2013
4 answers
1.4K+ views
Hi

I want to create a radiobutton group in telerik and get the selected item. 

Thanks
Lovella
Shinu
Top achievements
Rank 2
 answered on 24 Jul 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Hiba
Top achievements
Rank 1
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Hiba
Top achievements
Rank 1
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?