I was trying to have the validation happening at client side by adding the OnCommand ClientEvents to the grid. If invalid, the OnCommand will be cancelled.
However, after adding it in, it caused the Grid control to throw error "Unable to get property 'showInsertItem' of undefined or null reference" (can be viewed thru debug within IE). This has caused the "Add new Record" button of the Grid not working. If I take out the ClientEvents lines out, the affected function will be resumed. The funny thing was that it seemed it only got problem with "OnCommand". I tried few other, such as OnItemCreated, OnDoubleClick, without issues at all.
Any ideas? Attached please find my code.
@ Control Language="C#" AutoEventWireup="false" CodeBehind="Data018_WRN_RecallQryByVin.ascx.cs"I am using a RadGrid popup form. Due to the amount of data in the grid row, the edit popup for has three controls. One control is a Rad combobox to select the field to edit. Two text boxes exist. One text box is for the current field value in the database. Another text box is for the new value entered by the user. The problem is edit popup is not working correctly. The popup has no background color (it is clear). That the rad grid item data bound event is called for each post back. The edit popup form current item text box is blank. The rad combobox does not retain its values across post backs. The rad combobox also does not keep its selected value across post backs. I have tried both a user control popup form and a form template within the radgrid. No errors are given. The form does not work correctly. The text box values are all set based on the radcombobox selected value in the code behind. No data binding is taking place. The program I inherited is using similar code on another web page. My new page is different. The new page has five grids. One parent grid. The other grid's data is determined by the row selected in the parent grid.
Telerik RadControls for ASP.NET AJAX Q2 2011 SP1 is installed on the windows 7 computer. My website is C# asp.net web forms (.net framework 4). My browser is Internet Explorer 11. Any advice is greatly appreciated. I am not able to attach my code or past it in this thread.
Hi, is there a way to produce something similar to the following
https://resourcetrade.earth/data ?
Thank you
We are trying to display a distribution line chart. Behind it, we would like shaded areas to indicate P10, 25,50,75, 90 similar to the rough sketch below. How would we accomplish that background shading with htmlchart?
Thanks.
This works:
<ResourceTypes>
<telerik:ResourceType KeyField="id" Name="Vragenset" TextField="description" ForeignKeyField="VragensetID"
DataSourceID="sds_vragenset"></telerik:ResourceType>
<telerik:ResourceType KeyField="id" Name="Project" TextField="description" ForeignKeyField="ProjectID"
DataSourceID="sds_project"></telerik:ResourceType>
</ResourceTypes>
But this is not working:
<ResourceTypes>
<telerik:ResourceType KeyField="id" Name="VragensetID" TextField="description" ForeignKeyField="VragensetID"
DataSourceID="sds_vragenset"></telerik:ResourceType>
<telerik:ResourceType KeyField="id" Name="ProjectID" TextField="description" ForeignKeyField="ProjectID"
DataSourceID="sds_project"></telerik:ResourceType>
</ResourceTypes>
Mind that I names the Name the same as ForeignKeyField. Is this a bug or by design?
Marc
I am troubleshooting a program that someone else wrote and there is a grid that is missing a few column headers upon export to excel. The column headers and data showed up on screen but not on excel export. The first few columns would have headers and the rest of the columns displayed data but no headers. In the method that gets called by OnItemCommand, I have tried changing the header text by doing this:
gridMasterTableView.GetColumn(I).HeaderText = I;
but it doesn't seem to change anything on the excel.
In the method that is called by OnItemDataBound I tried to put a breakpoint on this line:
GridHeaderItem header = (GridHeaderItem)e.Item;
In the GridHeaderItem I noticed it only has a few of the columns.
I just want to fill the missing column headers. Is there a good place where I can access the datatable that gets exported to excel and put in the headers? In other words, if I only want to control what column name to put on excel export without touching the original source data, what would be a good place to do it and how to go about doing that?
Thanks.
We have a project that we store the connection string in a session (in page load).
When using the radscheduler reminder function it works for the first time but after that the Scheduler stops functioning and returns the error that connection string has not been initialized. Keep in mind we cannot change the way we use the connection string and we need to keep it stored in the session.
Has anyone faced the above problem before? Thanks in advance
I am trying to bind a List as the database for my RadGrid and I am getting the following error "Cannot find any bindable properties in an item from the datasource" although I have made sure and tested that the data source is returning valid data.
<
telerik:RadGrid
ID
=
"grdTest"
runat
=
"server"
AutoGenerateColumns
=
"true"
ShowStatusBar
=
"True"
OnNeedDataSource
=
"grdTest_NeedDataSource"
>
<
MasterTableView
AutoGenerateColumns
=
"true"
>
</
MasterTableView
>
</
telerik:RadGrid
>
protected
void
grdTest_NeedDataSource(
object
sender, GridNeedDataSourceEventArgs e)
{
int
ParentRulCode = 2611767;
List<Enrolment> MyEnrol = EnrolmentRepository.GetChildEnrolmentsFromRulCode(ParentRulCode);
grdTest.DataSource = MyEnrol;
}
Here is My Enrolment Class
public
class
Enrolment
{
public
Course MC;
public
Person MP;
public
int
RulCode;
public
DateTime StartDate;
public
DateTime EndDate;
public
string
ProgressStatus;
}