Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
262 views
So I am trying to use a radgrid to allow updates to my database, and while the page functions properly, I can't seem to save the data back to the database, any help you can offer would be appreciated greatly. I am new to both C# and asp.

Page Code:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ValidationEdit.aspx.cs" Inherits="EditPages_ValidationEdit" MasterPageFile="~/EUEMain.master"   %>
 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
 
 
<asp:Content ID="Content1" ContentPlaceHolderID="cphLeftNav" runat="Server">
    <asp:HyperLink ID="HomeLink" runat="server" NavigateUrl="..\Default.aspx" Text="Home" />
    <br />
    <asp:HyperLink ID="AddLink" runat="server" Text="Status Edit Page" />
    <br />
</asp:Content>
 
<asp:Content ID="Content2" ContentPlaceHolderID="cphContent" runat="Server">
    <p></p>
<p></p>
<p></p>
    <h1>Subdivision Statuses</h1>
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
</telerik:RadScriptManager>
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
  <AjaxSettings>
    <telerik:AjaxSetting AjaxControlID="RadGrid1">
      <UpdatedControls>
        <telerik:AjaxUpdatedControl ControlID="RadGrid1" LoadingPanelID="RadAjaxLoadingPanel1" />
      </UpdatedControls>
    </telerik:AjaxSetting>
  </AjaxSettings>
</telerik:RadAjaxManager>
    <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" />
    <telerik:RadGrid ID="RadGrid1" runat="server" DataModelID="Status" AllowPaging="True" AllowAutomaticUpdates="True" AllowAutomaticInserts="True"
        AllowAutomaticDeletes="true" AllowSorting="true" OnItemCreated="RadGrid1_ItemCreated"
        OnItemInserted="RadGrid1_ItemInserted" OnPreRender="RadGrid1_PreRender" OnInsertCommand="RadGrid1_InsertCommand" OnNeedDataSource="Radgrid1_NeedDataSource">
         
    <PagerStyle Mode="NextPrevAndNumeric" />
        <MasterTableView  AutoGenerateColumns="False"
            DataKeyNames="Description" CommandItemDisplay="Top">
            <Columns>
                <telerik:GridEditCommandColumn ButtonType="ImageButton" UniqueName="EditCommandColumn">
                </telerik:GridEditCommandColumn>
                <telerik:GridBoundColumn DataField="Description" HeaderText="Description" SortExpression="Description"
                    UniqueName="Description" >
                </telerik:GridBoundColumn>
                <telerik:GridCheckBoxColumn  DataField="Visible" HeaderText="Visible" SortExpression="Visible"
                    UniqueName="Visible">
                </telerik:GridCheckBoxColumn>
                <telerik:GridBoundColumn DataField="StatusType" HeaderText="Status Type" UniqueName="StatusType"></telerik:GridBoundColumn>
                <telerik:GridButtonColumn Text="Delete" CommandName="Delete" ButtonType="ImageButton" />
            </Columns>
            <EditFormSettings>
                <EditColumn ButtonType="ImageButton" />
            </EditFormSettings>
        </MasterTableView>
 
    </telerik:RadGrid>
    <h1>
        Track Statuses
        <telerik:RadGrid ID="RadGrid2" runat="server" DataModelID="Status" AllowPaging="True" AllowAutomaticUpdates="True" AllowAutomaticInserts="True"
        AllowAutomaticDeletes="true" AllowSorting="true" OnItemCreated="RadGrid1_ItemCreated"
        OnItemInserted="RadGrid1_ItemInserted" OnPreRender="RadGrid1_PreRender" OnInsertCommand="RadGrid1_InsertCommand" OnNeedDataSource="Radgrid1_NeedDataSource">
         
    <PagerStyle Mode="NextPrevAndNumeric" />
        <MasterTableView  AutoGenerateColumns="False"
            DataKeyNames="Description" CommandItemDisplay="Top">
            <Columns>
                <telerik:GridEditCommandColumn ButtonType="ImageButton" UniqueName="EditCommandColumn">
                </telerik:GridEditCommandColumn>
                <telerik:GridBoundColumn DataField="Description" HeaderText="Description" SortExpression="Description"
                    UniqueName="Description" >
                </telerik:GridBoundColumn>
                <telerik:GridCheckBoxColumn DataField="Visible" HeaderText="Visible" SortExpression="Visible"
                    UniqueName="Visible">
                </telerik:GridCheckBoxColumn>
                <telerik:GridBoundColumn DataField="StatusType" HeaderText="Status Type" UniqueName="StatusType"></telerik:GridBoundColumn>
                 
                <telerik:GridButtonColumn Text="Delete" CommandName="Delete" ButtonType="ImageButton" />
            </Columns>
            <EditFormSettings>
                <EditColumn ButtonType="ImageButton" />
            </EditFormSettings>
        </MasterTableView>
 
    </telerik:RadGrid>
    </h1>
     <asp:EntityDataSource ID="EntityDataSourceStatus" runat="server" ConnectionString="name=PtcDbModelEntities"
        DefaultContainerName="PtcDbModelEntities" EntitySetName="Status" OrderBy="it.[ContactName]"
        EntityTypeFilter="Description" EnableDelete="True" EnableFlattening="False" EnableInsert="True" EnableUpdate="True">
    </asp:EntityDataSource>
</asp:Content>

and the Code behind:
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Web.UI;
using Model;
using Telerik.Web.UI;
 
public partial class EditPages_ValidationEdit : BNSF.EUECommonApplication.EUEBasePage
{
 
    public List<Status> StatusList { get; set; }
    public object CurrentSubStatusList { get; set; }
 
    protected void Page_Load(object sender, EventArgs e)
    {
         
        AddLink.NavigateUrl = @"..\EditPages\ValidationEdit";
        if (!Page.IsPostBack)
        {
             
                using (PtcDbModel localDb = new PtcDbModel())
                {
                    var localTemp = (from tempList in localDb.Status
                                     where tempList.StatusType == "S"
                                     select tempList)
                                    .ToList();
                    var localTemp2 = (from tempList in localDb.Status
                                      where tempList.StatusType == "T"
                                      select tempList)
                                    .ToList();
                    CurrentSubStatusList = localTemp;
                    CurrentTrackStatusList = localTemp2;
 
                    var tempDetailList = CurrentSubStatusList;
                    var tempDetailList2 = CurrentTrackStatusList;
                    RadGrid1.DataSource = tempDetailList;
                    RadGrid2.DataSource = tempDetailList2;
                }
            }
        }
 
    public List<Status> CurrentTrackStatusList { get; set; }
 
 
    protected void RadGrid1_ItemCreated(object sender, Telerik.Web.UI.GridItemEventArgs e)
    {
        if (e.Item is GridEditableItem && e.Item.IsInEditMode)
        {
            if (!(e.Item is GridEditFormInsertItem))
            {
                GridEditableItem item = e.Item as GridEditableItem;
                GridEditManager manager = item.EditManager;
                GridTextBoxColumnEditor editor = manager.GetColumnEditor("Description") as GridTextBoxColumnEditor;
                editor.TextBoxControl.Enabled = true;
            }
        }
    }
    protected void RadGrid1_ItemInserted(object source, GridInsertedEventArgs e)
    {
        if (e.Exception != null)
        {
 
            e.ExceptionHandled = true;
            SetMessage("Customer cannot be inserted. Reason: " + e.Exception.Message);
 
        }
        else
        {
            SetMessage("New customer is inserted!");
        }
    }
    private void DisplayMessage(string text)
    {
        RadGrid1.Controls.Add(new LiteralControl(string.Format("<span style='color:red'>{0}</span>", text)));
    }
 
    private void SetMessage(string message)
    {
        gridMessage = message;
    }
 
    private string gridMessage = null;
 
    protected void RadGrid1_PreRender(object sender, EventArgs e)
    {
        if (!string.IsNullOrEmpty(gridMessage))
        {
            DisplayMessage(gridMessage);
            RadGrid1.DataBind();
            RadGrid2.DataBind();
        }
    }
 
    protected void RadGrid1_InsertCommand(object sender, GridCommandEventArgs e)
    {
        if (e.Item is GridEditableItem)
        {
            GridEditableItem editedItem = e.Item as GridEditableItem;
            //here editedItem.SavedOldValues will be the dictionary which holds the
            //predefined values
 
            //Prepare new dictionary object
            Hashtable newValues = new Hashtable();
            e.Item.OwnerTableView.ExtractValuesFromItem(newValues, editedItem);
            //the newValues instance is the new collection of key -> value pairs
            //with the updated ny the user data
        }
    }
 
 
    protected void Radgrid1_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
    {
        using (PtcDbModel localDb = new PtcDbModel())
        {
            var localTemp = (from tempList in localDb.Status
                             where tempList.StatusType == "S"
                             select tempList)
                            .ToList();
            
 
            var localTemp2 = (from tempList in localDb.Status
                              where tempList.StatusType == "T"
                              select tempList)
                                     .ToList();
            CurrentSubStatusList = localTemp;
            CurrentTrackStatusList = localTemp2;
 
            var tempDetailList = CurrentSubStatusList;
            var tempDetailList2 = CurrentTrackStatusList;
            RadGrid1.DataSource = tempDetailList;
            RadGrid2.DataSource = tempDetailList2;
 
        }
    }
}
Konstantin Dikov
Telerik team
 answered on 23 Jan 2015
1 answer
141 views
I have a grid as follows. EditMode=Batch, AllowMultiRowSelection, AllowMultiRowEdit = true

<telerik:RadGrid ID="RadGrid1" runat="server" ClientSettings-Selecting-AllowRowSelect="true" AutoGenerateColumns="False" AllowMultiRowSelection="true" OnNeedDataSource="RadGrid1_NeedDataSource" AllowMultiRowEdit="true">
       <MasterTableView EditMode="Batch" DataKeyNames="Discipline_ID" CommandItemDisplay="Top">
           <BatchEditingSettings EditType="Row" OpenEditingEvent="DblClick" />
           <CommandItemTemplate>
               <asp:ImageButton ID="Button_Save" runat="server" ToolTip="Save" ImageUrl="~/dhtmlx/imgs/save.png" Height="20" Width="20" style="padding:5px 0 0 5px;" OnClick="Button_Save_Click" />   
           </CommandItemTemplate>
           <Columns>
               <telerik:GridBoundColumn DataField="Discipline_ID" Display="false" UniqueName="Discipline_ID"></telerik:GridBoundColumn>
               <telerik:GridClientSelectColumn UniqueName="SelectCheckBox" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" HeaderStyle-Width="50px"></telerik:GridClientSelectColumn>
               <telerik:GridBoundColumn DataField="Name" HeaderText="Name" UniqueName="Name" AllowSorting="true"></telerik:GridBoundColumn>
               <telerik:GridBoundColumn DataField="Description" HeaderText="Description" UniqueName="Description" AllowSorting="true"></telerik:GridBoundColumn>
           </Columns>
       </MasterTableView>
   </telerik:RadGrid>


When I click the save button in the CommandItemTemplate it fires this event:

protected void Button_Save_Click(object sender, ImageClickEventArgs e)
    {
        foreach (GridDataItem item in RadGrid1.EditItems)
        {
            Hashtable newValues = new Hashtable();
            item.OwnerTableView.ExtractValuesFromItem(newValues, item);
        }
    }


When I try to update the items that have been edited in the grid the RadGrid1.EditItems.Count is always 0.

Why aren't the items that I have edited marked as edited when I try to save them?

Thanks





















Konstantin Dikov
Telerik team
 answered on 23 Jan 2015
2 answers
153 views
I have a number of forms and grids that use RadAjaxManager to setup AJAX settings. This works well after the first click. That first clicks always does a full page refresh which is slow and does not show the RadAjaxLoadingPanel graphic. Is there a way to force the page to register the controls correctly so any click is handled correctly by RadAjaxManager?

The controls are placed in web parts that appear in SharePoint pages.
Bill Wolff
Top achievements
Rank 1
 answered on 22 Jan 2015
1 answer
106 views
I have a client side data bind on my RadGrid. The Delete and Update Commands work perfectly, but when I try to insert a new row my code breaks at the Checkbox bind with the following: "Specified cast is not valid." I am new to C#, Asp, and Telerik controls, any help would be greatly appreciated.
Here is my Page Code:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ValidationEdit.aspx.cs" Inherits="EditPages_ValidationEdit" MasterPageFile="~/EUEMain.master" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
 
<asp:Content ID="Content1" ContentPlaceHolderID="cphLeftNav" runat="Server">
    <asp:HyperLink ID="HomeLink" runat="server" NavigateUrl="..\Default.aspx" Text="Home" />
    <br />
    <asp:HyperLink ID="AddLink" runat="server" Text="Status Edit Page" />
    <br />
</asp:Content>
 
<asp:Content ID="Content2" ContentPlaceHolderID="cphContent" runat="Server">
 
    <h1>Subdivision Statuses</h1>
 
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server" />
    <asp:Label ID="Label1" runat="server" EnableViewState="False" Font-Bold="True" ForeColor="#FF8080">
    </asp:Label>
    <asp:Label ID="Label2" runat="server" EnableViewState="False" Font-Bold="True" ForeColor="#00C000">
    </asp:Label>
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="RadGrid1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="RadGrid1" LoadingPanelID="RadAjaxLoadingPanel1" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>
 
    <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" />
 
    <div id="Testing">
        <telerik:RadGrid ID="RadGrid1" runat="server" DataSourceID="SqlDataSourceSub" AllowPaging="True" AllowAutomaticUpdates="True" AllowAutomaticInserts="True"
            AllowAutomaticDeletes="true" AllowSorting="true" AutoGenerateColumns="False" OnItemUpdated="RadGrid1_ItemUpdated"
            OnPreRender="RadGrid1_PreRender" OnItemInserted="RadGrid1_ItemInserted">
            <MasterTableView AutoGenerateColumns="False" CommandItemDisplay="TopAndBottom" DataKeyNames="StatusId" DataSourceID="SqlDataSourceSub">
                <Columns>
                    <telerik:GridEditCommandColumn>
                    </telerik:GridEditCommandColumn>
                    <telerik:GridBoundColumn DataField="StatusID" HeaderText="Status ID" UniqueName="StatusID" Visible="False" />
                    <telerik:GridBoundColumn DataField="StatusType" HeaderText="Status Type" UniqueName="StatusType" Visible="False" />
                    <telerik:GridBoundColumn DataField="Description" HeaderText="Description" UniqueName="Description" />
                    <telerik:GridCheckBoxColumn DataField="Visible" HeaderText="Visible" UniqueName="Visible" />
                    <telerik:GridButtonColumn CommandName="Delete" Text="Delete" UniqueName="column" />
                </Columns>
                <EditFormSettings EditFormType="Template">
                    <FormTemplate>
                        <table id="table1">
                            <tr>
                                <td>Subdivision Status Details</td>
                            </tr>
                            <tr>
                                <td>
                                    <table id="Table2">
                                        <tr>
                                            <td >Status ID</td>
                                            <td>
                                                <asp:Label runat="server" ID="StatusIdLabel" Text='<%#Bind("StatusId") %>' Visible="False"></asp:Label>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>Status Type</td>
                                            <td>
                                                <asp:TextBox runat="server" ID="StatusTypeTextBox" Text='<%#Bind("StatusType") %>'></asp:TextBox>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td runat="server">Description</td>
                                            <td>
                                                <asp:TextBox runat="server" ID="DescriptionTextBox" Text='<%#Bind("Description") %>'></asp:TextBox>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>Visible</td>
                                            <td>
                                                <asp:CheckBox  Checked='<%#Bind("Visible") %>' ID="VisibleCheckBox" runat="server" />
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <asp:Button ID="btnUpdate" Text='<%# (Container is GridEditFormInsertItem) ? "Insert" : "Update" %>'
                                                    runat="server" CommandName='<%# (Container is GridEditFormInsertItem) ? "PerformInsert" : "Update" %>'></asp:Button
                                    <asp:Button ID="btnCancel" Text="Cancel" runat="server" CausesValidation="False"
                                        CommandName="Cancel"></asp:Button>
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                        </table>
                    </FormTemplate>
                </EditFormSettings>
            </MasterTableView>
        </telerik:RadGrid>
    </div>
 
    <asp:SqlDataSource ID="SqlDataSourceSub" runat="server" ConnectionString="<%$ ConnectionStrings:PtcDbModelEntities %>"
        DeleteCommand="DELETE FROM [dbo].[Status] WHERE [StatusId] = @StatusId"
        InsertCommand="INSERT INTO [dbo].[Status] ([StatusType], [Description], [Visible], VALUES (@StatusType, @Description, @BitVisible)"
        SelectCommand="SELECT [StatusId], [StatusType], [Visible], [Description] FROM [dbo].[Status] where StatusType = 'S'"
        UpdateCommand="UPDATE [dbo].[Status] SET [StatusType] = @StatusType, [Description] = @Description,  Visible = @Visible  WHERE [StatusId] = @StatusId">
        <DeleteParameters>
            <asp:Parameter Name="StatusId" Type="Int32"></asp:Parameter>
        </DeleteParameters>
        <InsertParameters>
            <asp:Parameter Name="StatusType" Type="String"></asp:Parameter>
            <asp:Parameter Name="Description" Type="String"></asp:Parameter>
            <asp:Parameter Name="Visible" Type="Boolean"></asp:Parameter>
        </InsertParameters>
        <UpdateParameters>
            <asp:Parameter Name="StatusType" Type="String"></asp:Parameter>
            <asp:Parameter Name="Description" Type="String"></asp:Parameter>
            <asp:Parameter Name="Visible" Type="Boolean"></asp:Parameter>
            <asp:Parameter Name="StatusId" Type="Int32" />
        </UpdateParameters>
    </asp:SqlDataSource>
and my code Behind (C#):
using System;
using System.Web.UI.WebControls;
using Telerik.Web.UI;
 
public partial class EditPages_ValidationEdit : BNSF.EUECommonApplication.EUEBasePage
{
    protected void Page_Load(object sender, EventArgs e)
    {
        AddLink.NavigateUrl = @"..\EditPages\ValidationEdit.aspx";
    }
    protected void RadGrid1_ItemUpdated(object source, Telerik.Web.UI.GridUpdatedEventArgs e)
    {
        SqlDataSourceSub.UpdateParameters["Description"].DefaultValue = e.ToString();
        SqlDataSourceSub.UpdateParameters["StatusType"].DefaultValue = e.ToString();
        SqlDataSourceSub.UpdateParameters["Visible"].DefaultValue = e.ToString();
 
        if (e.Exception != null)
        {
            e.KeepInEditMode = true;
            e.ExceptionHandled = true;
            DisplayMessage(true, "Status " + e.Item.OwnerTableView.DataKeyValues[e.Item.ItemIndex]["StatusId"] + " cannot be updated. Reason: " + e.Exception.Message);
        }
        else
        {
            DisplayMessage(false, "Status " + e.Item.OwnerTableView.DataKeyValues[e.Item.ItemIndex]["StatusId"] + " updated");
        }
    }
 
    protected void RadGrid1_ItemInserted(object source, GridInsertedEventArgs e)
    {
         
        SqlDataSourceSub.InsertParameters["StatusType"].DefaultValue = e.ToString();
        SqlDataSourceSub.InsertParameters["Description"].DefaultValue = e.ToString();
        SqlDataSourceSub.InsertParameters["Visible"].DefaultValue = e.ToString();
    }
 
    protected void RadGrid1_ItemDeleted(object source, GridDeletedEventArgs e)
    {
        if (e.Exception != null)
        {
            e.ExceptionHandled = true;
            DisplayMessage(true, "Status " + e.Item.OwnerTableView.DataKeyValues[e.Item.ItemIndex]["StatusId"] + " cannot be deleted. Reason: " + e.Exception.Message);
        }
        else
        {
            DisplayMessage(false, "Status " + e.Item.OwnerTableView.DataKeyValues[e.Item.ItemIndex]["StatusId"] + " deleted");
        }
    }
 
    private void DisplayMessage(bool isError, string text)
    {
        Label label = (isError) ? this.Label1 : this.Label2;
        label.Text = text;
    }
 
    protected void RadGrid1_ItemCommand(object source, GridCommandEventArgs e)
    {
        if (e.CommandName == RadGrid.InitInsertCommandName) //"Add new" button clicked
        {
            GridEditCommandColumn editColumn = (GridEditCommandColumn)RadGrid1.MasterTableView.GetColumn("EditCommandColumn");
            editColumn.Visible = false;
        }
        else if (e.CommandName == RadGrid.RebindGridCommandName && e.Item.OwnerTableView.IsItemInserted)
        {
            e.Canceled = true;
        }
        else
        {
            GridEditCommandColumn editColumn = (GridEditCommandColumn)RadGrid1.MasterTableView.GetColumn("EditCommandColumn");
            if (!editColumn.Visible)
                editColumn.Visible = true;
        }
    }
    protected void RadGrid1_PreRender(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            RadGrid1.EditIndexes.Add(0);
            RadGrid1.Rebind();
        }
    }
}

Matthew
Top achievements
Rank 1
 answered on 22 Jan 2015
5 answers
784 views
I am getting this error when a user clicks Export on the radGrid heading:

Specified argument was out of the range of valid values.
Parameter name: index

[ArgumentOutOfRangeException: Specified argument was out of the range of valid values.
Parameter name: index]
System.Web.UI.ControlCollection.get_Item(Int32 index) +11120470
Telerik.Web.UI.GridGroupPanel.get_MainTable() +54
Telerik.Web.UI.GridGroupPanel.OnPreRender(EventArgs e) +56

Any ideas? This also happens for PDF and Word exports. The grid uses an ObjectDataSource with EnablePaging true and a SortParameterName. Other grid functions like sorting, filtering, paging, and grouping work as advertised. The exports are setup in the markup like this:

    <ExportSettings Excel-Format="Html" Word-Format="Html" FileName="Batch"
        IgnorePaging="true" HideStructureColumns="true" OpenInNewWindow="true" ExportOnlyData="true">
Bill Wolff
Top achievements
Rank 1
 answered on 22 Jan 2015
1 answer
54 views
Hi All ,

I am using Batch Editing for Insert, Update and Delete operations in my radgrid. I have taken reference from
http://demos.telerik.com/aspnet-ajax/grid/examples/data-editing/batch-editing/defaultcs.aspx.

I am facing a weird issue. When I try to delete the last row in the radgrid (or the underlying database table), the ItemCommand event of the grid
is not fired and hence it doesn't get deleted.
However, delete works fine in any other scenario.

Please help.
Maria Ilieva
Telerik team
 answered on 22 Jan 2015
3 answers
757 views
I am using the radgrid with group expressions to group and binding in the code. The expand works but collapse doesn't work on the same group. When I expand the other group, it collapses the previously opened group but when it collapse the expanded group, it doesn't work. I tried GroupLoad = "Client". It works but after few expand and close, the grid doesn't refresh and shows all grid lines all over. 

What am I doing wrong?

Vijai
vtmac
Top achievements
Rank 1
 answered on 22 Jan 2015
1 answer
93 views
Hello,

I have a small problem every time I refreshed my page.

Indeed, the size of my columns shrink gradually, so that I can even do not see ...
Here are some screenshot:

First screen : http://puu.sh/eRxuj/ee67764f9a.png
After 5 refresh : http://puu.sh/eRxzR/6270233218.png


ColumnSeries columnEffluent = new ColumnSeries();
columnEffluent.Gap = 1.5;
columnEffluent.Name = "Effluents traités";
columnEffluent.LabelsAppearance.Color = System.Drawing.Color.Blue;
columnEffluent.Appearance.FillStyle.BackgroundColor = System.Drawing.Color.FromArgb(3, 133, 182);
columnEffluent.TooltipsAppearance.DataFormatString = "{0} m³/j";
 
LineSeries linePluvio = new LineSeries();
linePluvio.Name = "Pluviométrie";
linePluvio.AxisName = "AdditionalAxis";
linePluvio.MarkersAppearance.BorderColor = System.Drawing.Color.Red;
linePluvio.MarkersAppearance.BackgroundColor = System.Drawing.Color.Red;
linePluvio.Appearance.FillStyle.BackgroundColor = System.Drawing.Color.Red;
linePluvio.LabelsAppearance.Color = System.Drawing.Color.Red;
linePluvio.LineAppearance.LineStyle = Telerik.Web.UI.HtmlChart.Enums.ExtendedLineStyle.Smooth;
linePluvio.TooltipsAppearance.DataFormatString = "{0} mm";


Hope you can help me
Naografix
Top achievements
Rank 1
 answered on 22 Jan 2015
3 answers
330 views
Hi,

I've a question regarding RadDataForm.
In my dataForm, I've a textBox (ie. "_txtOpenDate").
When I click on Insert button, I want to change the date with the Today date.

How can I do this ? I tried the FindControl("txtOpenDate") method but each time I 've a null reference (every method such as ItemInserting, ItemCommand ...)

Thanks
Nicolas
Top achievements
Rank 1
 answered on 22 Jan 2015
1 answer
147 views
Hi

I want to restrict user to enter multiple entries per day in week view scheduler. It should be only one entry. It should not create additional row. I am attaching sccreenshot of my requirement in this post. Please guide me to achive this. (I am using Resource group also in this case)
Boyan Dimitrov
Telerik team
 answered on 22 Jan 2015
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?