Hi Team,
I tried following steps to use RadMultiSelect dropdown in my project but getting compile time error .
1) I have registered Telerik.Web.UI assembly in aspx page
2) Added RadScriptManager and RadSkinManager on aspx page.
3) then added following code -
requiredMultiSelect.Value = {"Anne King", "Andrew Fuller"}
And getting compile time error -
Hi,
Long time Webforms developer here, but just starting out with Telerik Rad controls.
I can't for the life of me figure out how to get the "Insert Record" button to show up on my Grid that has a Master-Detail relationship.
I looked at the code sample and can't figure out what I am missing.
Any help you could provide would be appreciated.
<telerik:RadGrid ID="gvCurrentSalaries" runat="server" AllowPaging="True" DataSourceID="sqlCurrentSalaries" PageSize="50" Visible="False" RenderMode="Lightweight" AllowSorting="True" AllowAutomaticInserts="True" AutoGenerateColumns="False" OnInsertCommand="gvCurrentSalaries_InsertCommand">
<GroupingSettings CollapseAllTooltip="Collapse all groups"></GroupingSettings>
<ExportSettings ExportOnlyData="True" FileName="Workforce-Salary" IgnorePaging="True">
<Excel FileExtension="xlsx" Format="Xlsx" />
</ExportSettings>
<ClientSettings AllowColumnsReorder="True" ReorderColumnsOnClient="True">
<Selecting AllowRowSelect="True" />
</ClientSettings>
<MasterTableView CommandItemDisplay="Top" DataSourceID="sqlCurrentSalaries" DataKeyNames="PersonID">
<DetailTables>
<telerik:GridTableView runat="server" DataKeyNames="PersonID" DataSourceID="sqlSalaryHistory">
<ParentTableRelation>
<telerik:GridRelationFields DetailKeyField="PersonID" MasterKeyField="PersonID" />
</ParentTableRelation>
<RowIndicatorColumn ShowNoSortIcon="False" Visible="False">
</RowIndicatorColumn>
<ExpandCollapseColumn Created="True" ShowNoSortIcon="False">
</ExpandCollapseColumn>
<EditFormSettings>
<EditColumn ShowNoSortIcon="False">
</EditColumn>
</EditFormSettings>
<Columns>
<telerik:GridBoundColumn DataField="Salary" FilterControlAltText="Filter FullName column" HeaderText="Current Salary" ShowNoSortIcon="False" UniqueName="Salary" DataFormatString="{0:c}">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="StartDate" FilterControlAltText="Filter FullName column" HeaderText="Start Date" ShowNoSortIcon="False" UniqueName="StartDate" DataFormatString="{0:d}">
</telerik:GridBoundColumn>
</Columns>
</telerik:GridTableView>
</DetailTables>
<CommandItemSettings ShowExportToExcelButton="True" ShowExportToPdfButton="True" ShowAddNewRecordButton="False" />
<RowIndicatorColumn ShowNoSortIcon="False" Visible="False"></RowIndicatorColumn>
<ExpandCollapseColumn ShowNoSortIcon="False" Created="True"></ExpandCollapseColumn>
<Columns>
<telerik:GridBoundColumn DataField="FullName" FilterControlAltText="Filter FullName column" HeaderText="Full Name" ShowNoSortIcon="False" UniqueName="FullName">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="PersonType" FilterControlAltText="Filter FullName column" HeaderText="Person Type" ShowNoSortIcon="False" UniqueName="PersonType">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Salary" FilterControlAltText="Filter FullName column" HeaderText="Current Salary" ShowNoSortIcon="False" UniqueName="Salary" DataFormatString="{0:c}">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="StartDate" FilterControlAltText="Filter FullName column" HeaderText="Start Date" ShowNoSortIcon="False" UniqueName="StartDate" DataFormatString="{0:d}">
</telerik:GridBoundColumn>
</Columns>
<EditFormSettings>
<EditColumn ShowNoSortIcon="False"></EditColumn>
</EditFormSettings>
</MasterTableView>
<HeaderStyle Font-Bold="True" HorizontalAlign="Left" />
<FilterMenu RenderMode="Lightweight"></FilterMenu>
<HeaderContextMenu RenderMode="Lightweight"></HeaderContextMenu>
</telerik:RadGrid>
I can get the render suggested actions to work when its loaded up, but when the user selects an option, i want to render more suggested options for them to select. I have the onpost firing. What am i missing here. this code fires but i dont see the options appear in the chat window.
function onPost(e) {
DLL: Progress Telerik UI ASP NET AJAX Versión 2020.2.617.40
Hi!,
I have a problem with dynamically loading data, and subsequently filtering data from the headers of a radgrid.
The radgrid data is loaded dynamically through the selection of a radcombo with Id "rcb_Views", and this loads a sql server database view into a sql SqlDataSource "eds_Generic" and binds it to the grid.
The problem is that filtering by grid headers also has to be implemented, and it works if the selection in the combo does not change. But when the selection, in order to load a new data view, and regenerate all the data in the radgrid, it gives an error:
"[column] is neither a DataColumn nor a DataRelation for the DefaultView table.
The problem seems clear, and it is that it does not refresh either the model or the data, since the error column belongs to the schema of the model of the previous view, but I have not been able to solve it by changing the data source of the data, doing a rebind, etc. .
Can someone guide me on how I can correct the problem?
ASPX
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentMain" runat="Server">
<section class="section-admin-main">
<h1 class="page-title">
<asp:Label ID="lblTitle" runat="server" Text="Informes"></asp:Label>
</h1>
<telerik:RadAjaxManagerProxy ID="RadAjaxManager1" runat="server">
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="rcb_Views">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="rcb_Views"></telerik:AjaxUpdatedControl>
<telerik:AjaxUpdatedControl ControlID="RG_DistributorsWithoutParts"></telerik:AjaxUpdatedControl>
<telerik:AjaxUpdatedControl ControlID="eds_Generic"></telerik:AjaxUpdatedControl>
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="RG_DistributorsWithoutParts">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="rcb_Views"></telerik:AjaxUpdatedControl>
<telerik:AjaxUpdatedControl ControlID="RG_DistributorsWithoutParts"></telerik:AjaxUpdatedControl>
<telerik:AjaxUpdatedControl ControlID="eds_Generic"></telerik:AjaxUpdatedControl>
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManagerProxy>
<div id="div_combo">
<telerik:RadComboBox ID="rcb_Views" runat="server" MaxHeight="200" Width="315" OnSelectedIndexChanged="rcb_Views_SelectedIndexChanged" DataSourceID="eds_ViewNames"
DataTextField="description" DataValueField="ViewName" AutoPostBack="true" Label="Seleccione los datos a mostrar: ">
</telerik:RadComboBox>
</div>
<telerik:RadGrid ID="RG_DistributorsWithoutParts" runat="server" Height="500px" AllowPaging="True" ShowFooter="True"
AllowSorting="True" AutoGenerateColumns="True" ShowStatusBar="True" AllowFilteringByColumn="True" DataSourceID="eds_Generic"
OnItemCommand="RG_DistributorsWithoutParts_ItemCommand" CellSpacing="-1" Culture="es-ES" GridLines="Both">
<GroupingSettings CaseSensitive="false" />
<MasterTableView Width="100%" CommandItemDisplay="Top" CommandItemSettings-ShowAddNewRecordButton="false" CommandItemSettings-ShowRefreshButton="true" CommandItemSettings-ShowExportToExcelButton="true" PageSize="50">
<CommandItemSettings ShowAddNewRecordButton="False" ShowExportToExcelButton="True"></CommandItemSettings>
<Columns>
</Columns>
</MasterTableView>
<ClientSettings>
<Scrolling AllowScroll="true" UseStaticHeaders="false" SaveScrollPosition="false" />
<Resizing AllowColumnResize="true" AllowResizeToFit="true" />
</ClientSettings>
</telerik:RadGrid>
<asp:SqlDataSource ID="eds_Generic" runat="server" ConnectionString="<%$ ConnectionStrings:LMSViewsConnString %>" SelectCommand="SELECT * FROM [man_participantes]"></asp:SqlDataSource>
<asp:SqlDataSource ID="eds_ViewNames" runat="server" ConnectionString="<%$ ConnectionStrings:LMSViewsConnString %>" SelectCommand="SELECT * FROM [v_ViewNames]"></asp:SqlDataSource>
</section>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="FooterScripts" runat="Server">
<style type="text/css">
input[type="checkbox"] {
-webkit-appearance: checkbox;
}
input[type="radio"] {
-webkit-appearance: radio;
}
</style>
<script type="text/javascript">
function pageLoad() {
var grid = $find('<%=RG_DistributorsWithoutParts.ClientID %>');
var columns = grid.get_masterTableView().get_columns();
for (var i = 0; i < columns.length; i++) {
columns[i].resizeToFit();
}
}
</script>
</asp:Content>
protected void Page_Load(object sender, EventArgs e)
{
(this.Master as BaseMaster).setVisibilityMenu(false);
this.meth_TranslateGrids(RG_DistributorsWithoutParts);
if (rcb_Views.SelectedValue != "")
{
eds_Generic.SelectCommand = "SELECT * FROM [" + rcb_Views.SelectedValue + "]";
}
if (!IsPostBack)
{
rcb_Views.DataBind();
eds_Generic.SelectCommand = "SELECT * FROM [" + rcb_Views.SelectedValue + "]";
RG_DistributorsWithoutParts.DataBind();
}
}
protected void rcb_Views_SelectedIndexChanged(object sender, Telerik.Web.UI.RadComboBoxSelectedIndexChangedEventArgs e)
{
eds_Generic.SelectCommand = "SELECT * FROM [" + rcb_Views.SelectedValue + "]";
RG_DistributorsWithoutParts.DataBind();
}
I am able to bind pie chart data from code behind but I am not sure how to bind my Javascript object to Pie chart.
I am using ASP.NET Web Form and using AJAX to call Handler. I need to bind data after handler returns data.
To add a PDF file to a RadRotator control, the forum has a link to some code in Rich Content which has this:
<
div
class
=
"image"
>
<
img
src='images/pic<%# XPath("Number") %>.gif' height="75" width="69" alt="" title=""
style="border: 0px" />
</
div
>
<
div
class
=
"flashMovie"
>
<
object
classid
=
"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase
=
"http://active.macromedia.com/flash4/cabs/swflash.cab#version=4,0,0,0"
width
=
"165"
height
=
"74"
>
<
param
name
=
"movie"
value='images/Movie<%# XPath("Number") %>.swf' />
<
param
name
=
"quality"
value
=
"high"
/>
<
param
name
=
"bgcolor"
value
=
"#FFFFFF"
/>
<
param
name
=
"wmode"
value
=
"transparent"
/>
<
object
type
=
"application/x-shockwave-flash"
data='images/Movie<%# XPath("Number") %>.swf'
width="165" height="74">
<
param
name
=
"wmode"
value
=
"transparent"
/>
</
object
>
</
object
>
</
div
>
<
div
class
=
"orderDetails"
>
order:
<
asp:DropDownList
runat
=
"server"
>
<
asp:ListItem
Value
=
"Vase"
>Vase</
asp:ListItem
>
<
asp:ListItem
Value
=
"Card"
>Card</
asp:ListItem
>
<
asp:ListItem
Value
=
"Box"
>Box</
asp:ListItem
>
</
asp:DropDownList
>
<
br
/>
price: <
b
>$<%# XPath("Content")%></
b
>
<
br
/>
<
a
href
=
"#"
class
=
"orderInfo"
>details »</
a
>
</
div
>
The Telerik answer about adding a PDF file says use the PDF's iFrame to add to the RadRotator, but iFrames are deprecated, and there is no iFrame in this code. Can anyone provide a modern solution that specifically shows how to add an existing PDF file to a RadRotator?
Hi all
I have a radgrid with 1 detail table.
The master table retrieves data using a SQLDataSource ,a stored procedure and session value as a parameter - this works fine.
The detail table also uses a SQLDataSource and a stored procedure but the parameter for this is the key field from the master table and not a session field.
How do I go about grabbing the key field from the master and pass it to my stored procedure?
Any help greatly apprciated.
Hello
i'm stuck with a simple example.
I have a RadGrid with multiple column avec ExcelFilter activated.
When in a column, you have data like 'test AND test' the Filter got no FilterExpression when you select this particular line in the filter with a tickbox.
If you use the Filter fonction normally (Contain) it work.
Here is a simple exemple.
Default.aspx :
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
<telerik:RadStyleSheetManager id="RadStyleSheetManager1" runat="server" />
</head>
<body>
<form id="form1" runat="server">
<telerik:RadScriptManager ID="RadScriptManager1" runat="server">
<Scripts>
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" />
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" />
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js" />
</Scripts>
</telerik:RadScriptManager>
<div>
<telerik:RadGrid ID="GridFile" runat="server"
OnNeedDataSource="ContextGrid_NeedDataSource"
AllowSorting="true"
AllowFilteringByColumn="True"
FilterType="HeaderContext"
EnableHeaderContextMenu="true"
EnableHeaderContextFilterMenu="true"
OnFilterCheckListItemsRequested="RadGrid1_FilterCheckListItemsRequested"
FilterMenu-EnableRoundedCorners="false"
>
<MasterTableView AutoGenerateColumns="false" TableLayout="Auto">
<Columns>
<telerik:GridBoundColumn UniqueName="Creation" DataField="Creation" HeaderText="Creation" FilterCheckListEnableLoadOnDemand="true"/>
<telerik:GridBoundColumn UniqueName="Name" DataField="Name" HeaderText="Name" FilterCheckListEnableLoadOnDemand="true"/>
</Columns>
</MasterTableView>
</telerik:RadGrid>
</div>
</form>
</body>
</html>
And Defaults.aspx.cs
using System.Data;
using Telerik.Web.UI;
public partial class Default : System.Web.UI.Page
{
protected void ContextGrid_NeedDataSource(object source, Telerik.Web.UI.GridNeedDataSourceEventArgs e)
{
DataTable table = new DataTable();
GridFile.DataSource = getTable();
}
protected void RadGrid1_FilterCheckListItemsRequested(object sender, GridFilterCheckListItemsRequestedEventArgs e)
{
string DataField = (e.Column as IGridDataColumn).GetActiveDataField();
DataTable table = getTable();
table.DefaultView.Sort = DataField + " asc";
e.ListBox.DataSource = table.DefaultView.ToTable(true, DataField);
e.ListBox.DataKeyField = DataField;
e.ListBox.DataTextField = DataField;
e.ListBox.DataValueField = DataField;
e.ListBox.DataBind();
}
protected DataTable getTable()
{
DataTable table = new DataTable();
table.Columns.Add("Creation", typeof(string));
table.Columns.Add("Name", typeof(string));
int i = 0;
for (i=0; i < 10; i++)
{
table.Rows.Add(
"Name " + i,
i + " The AND a test"
) ;
}
return table;
}
}
Selection and Error in the 2 captures.
Works with OR also.Any Clues ?
Thinks it's the same error like the quote.
Thanks a lot
Benjamin