protected void Page_Load(object sender, EventArgs e)
{
cboSelectReport.Attributes.Add("onchange", "DisplayNewReport();");
string sqlString ="declare @startdate datetime; declare @enddate datetime;";
sqlString = sqlString + "set @startdate = '" + dtpStart.SelectedDate.ToString() + "';";
sqlString = sqlString + "set @enddate = '" + dtpEnd.SelectedDate.ToString() + "';";
radgrid.Skin = "Outlook";
ReportSource.SelectCommand = sqlString + ConfigurationManager.AppSettings["sqlcommand6"];
ReportSource.DataBind();
radgrid.Rebind();
}
public void radgrid_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
{
radgrid.DataSource = ReportSource;
}
Hi
I am really struggling to find a how to edit a textbox. I have a grid edited with a ascx WebUserControl. Within the ascx I the following
var pSalesOrderNumber = $find("<%= txtOrderNumber.ClientID %>");
It is undefined. I tried using $telerik.findControl but still no luck. Sadly out of my depth. Any help would be much appreciated
Hi
I have created a TelerikPivotGrid which displays a count of record per department and Type.
The data in the cell within the grid is clickable, and when a user clicks on I need to get the name of the column and name of the row for the cell they have clicked on.
Please can anyone advise how to get the values of the grid when a user clicks on the cell within the grid?
Thank you
Greetings,
I am using the RadGrid control with advanced data binding, virtualization and infinite scrolling and everything is going well. However, I need to perform some actions on the rows that are data-dependent. For this, I am using the ItemDataBound server-side event and OnRowDataBound client-side event. However, this seems to come with an implementation and maintenance overhead, since I have to basically implement the same behavior twice, in two diferent places and two different languages. Reading through the documentation and other posts, this seems to be a virtualization limitation, and the consequence of the fact that the initial dataset is bound server-side, while subsequently fetched rows are bound client-side? (like this answer would suggest: https://www.telerik.com/forums/radgrid-not-upating-columns-with-virtualization-enabled#4166877 )
I am curious if there would be a way to avoid this duplication - either by somehow manually evaluating OnRowDataBound function for the initial dataset, or perhaps by returning 0 rows in the NeedsDataSource method for initial load, and then triggering a client-side fetch after the "empty" grid is rendered? Even if this would cause an extra http request, it seems like a preferable alternative in my case.
Best regards,
Marko
I'm using version 2022.2.622.45.
If the checkboxes are displayed in the RadComboBox, the NVAD cannot read out the actual items in the combo box, and only give out the sound 'blank'.
Maybe there's special key for the navigation?
I have a RadGrid in a Jobs page which, when in edit mode, opens a JobCost.ascx WebUserControl. From the .ascx WebUserControl I open a popup page to search for OrderNumbers using RadOpen.
function openWinOrder()
{
var oWnd = radopen("SalesOrders.aspx", "WinOpenSalesOrder", 1000, 500, 00, 50);
}
function OnClientCloseOrder() {
var arg = args.get_argument();
if (arg) {
var mSalesOrderNumber = arg.mSalesOrderNumber;
var pSalesOrderNumber = $find("<%= txtOrderNumber.ClientID %>");
pSalesOrderNumber.set_value("Hello");
}
}
<telerik:RadWindowManager ID="RadWindowManager2" ShowContentDuringLoad="false" VisibleStatusbar="false"
ReloadOnShow="true" runat="server" Skin="WebBlue" EnableShadow="true">
<Windows>
<telerik:RadWindow ID="WinOpenSalesOrder" runat="server" Behaviors="Close" OnClientClose="OnClientCloseOrder"
NavigateUrl="SalesOrders.aspx">
</telerik:RadWindow>
</Windows>
</telerik:RadWindowManager>
Am I doing something daft or is there an issue du to there ending up with more than one RadWindowManager
I have a Telerik RadGrid using an ascx web form user control for editing and adding new records to the grid.
On the web form control I have DropDown setup with this
<
asp:DropDownList
ID
=
"ddlComparisonSubjects"
runat
=
"server"
DataTextField
=
"SubjectName"
DataValueField
=
"SubjectId_FK"
AppendDataBoundItems
=
"true"
SelectedValue='<%# DataBinder.Eval(Container, "DataItem.SubjectId_FK") %>'>
</
asp:DropDownList
>
And My C# code is this
var SubjectNames = db.T_Subjects.Where(a => a.CaseId_FK == intCaseId).Distinct().ToList();
ddlComparisonSubjects.DataTextField =
"SubjectName"
;
ddlComparisonSubjects.DataValueField =
"SubJectId"
;
ddlComparisonSubjects.DataSource = SubjectNames;
//ddlComparisonSubjects.Items.Clear();
//ddlComparisonSubjects.SelectedIndex = -1;
//ddlComparisonSubjects.SelectedValue = null;
//ddlComparisonSubjects.ClearSelection();
ddlComparisonSubjects.DataBind();
ddlComparisonSubjects.Items.Insert(0,
"--Select--"
);
The code lines commented out were added while troubleshooting this issue. They did not solve the problem so I commented them out. I have left them so you can see what I have tried to do to fix the problem.
Everything works fine if I am editing an existing record. However when I try to add a new record I get this error message:
'ddlComparisonSubjects' has a SelectedValue which is invalid because it does not exist in the list of items. Parameter name: value
I know the Parameter names are correct because the drop down works in edit mode.
So why do these drop downs work in edit mode but not in insert mode and how can I fix it?
How can I have full control of the Insert Template (e.g. I would like to create my own label and formatting for the label) inside the Template?
For example, the insert automatically shows the column header, but when I convert the field to a template it still shows the column header in addition to whatever additional stuff I put in the Insert template.
- Item 1 on the attached image comes from the column header. I'd like to get rid of that.
Mainly interested in a Detail Insert Template if it makes any difference on how to do this.
While we are at it... how do I change the Save/Cancel Icons in the Insert Item for a Detail?
- item 2 on the attached image is what I'd like to change
I am creating a mobile website using radcomboboxes inside of update controls that are set to autopostback = true. All of the controls work except on the page's initial load the UI elements are enlarged and look more like buttons. They are still able to be selected and after the controls postback the elements still do not go back to a normal size. Only after a postback from another control do the UI elements shrink down to a normal size.
I have tested the radcombobox with checkboxes enabled outside of the update panel and this behavior does not change. I have a master page that contains jQuery files located in the header, and when I remove one of the js files, the problem disappears with the UI elements disappearing. Can anyone help me figure out what is preventing the UI elements from rendering properly?
On Load:
After postback: