OnClientItemsRequesting simply cancels the request if less than 3 chars are typed, example from the knowledge base.<telerik:RadComboBox ID="rcbOrganizationName" Runat="server" OnSelectedIndexChanged="RcbOrganizationNameSelectedIndexChanged" OnItemsRequested="RcbOrganizationNameItemsRequested" OnClientItemsRequesting="OnClientItemsRequesting" EnableLoadOnDemand="true" AllowCustomText="True" AutoPostBack="True" EmptyMessage="Choose" MarkFirstMatch="false" EnableItemCaching="true" CausesValidation="false" TabIndex="2" ShowMoreResultsBox="false" MaxLength="50" MaxHeight="300px" Width="250px"></telerik:RadComboBox >e.SeriesItem.ActiveRegion.Tooltip = toolTip.ToString();
it assign the toolTip to the two serieschart.Series[0].Items[e.SeriesItem.Index].ActiveRegion.Tooltip = toolTip.ToString();
chart.Series[1][e.SeriesItem.Index].ActiveRegion.Tooltip =
"Hi Series 2";
I get exception:
Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Line 459: RadChart chart = (RadChart) sender;
Line 460: chart.Series[0].Items[e.SeriesItem.Index].ActiveRegion.Tooltip = toolTip.ToString();
Line 461: chart.Series[1][e.SeriesItem.Index].ActiveRegion.Tooltip = "Hi Series 2";
|
void
ChartFinancialImpact_ItemDataBound(object sender, ChartItemDataBoundEventArgs e)
{
DataRowView physicianDeviation = (DataRowView)e.DataItem;
StringBuilder toolTip = new StringBuilder();
toolTip.Append("Load:" + physicianDeviation["PhysicianLoad"].ToString() );
//e.SeriesItem.ActiveRegion.Tooltip = toolTip.ToString();
RadChart chart = (RadChart) sender;
chart.Series[0].Items[e.SeriesItem.Index].ActiveRegion.Tooltip = toolTip.ToString();
//chart.Series[1][e.SeriesItem.Index].ActiveRegion.Tooltip = "Hi Series 1"; ==> ERROR
}
How can i bind GridDropDownColumn with dataset from behind code
telerik:RadGrid ID="radgdBOQ" runat="server" AutoGenerateColumns="False" GridLines="None" OnNeedDataSource="radgdBOQ_NeedDataSource" OnInsertCommand="radgdBOQ_InsertCommand" ShowStatusBar="True" OnDeleteCommand="radgdBOQ_DeleteCommand" OnUpdateCommand="radgdBOQ_UpdateCommand" Skin="WebBlue"> <MasterTableView DataKeyNames="bqmiBoqID" CommandItemDisplay="TopAndBottom"> <CommandItemSettings ExportToPdfText="Export to Pdf"></CommandItemSettings> <Columns> <telerik:GridEditCommandColumn ButtonType="ImageButton" HeaderButtonType="None" HeaderText="Edit"> <HeaderStyle HorizontalAlign="Center" Width="35px" /> <ItemStyle HorizontalAlign="Center" /> </telerik:GridEditCommandColumn> <telerik:GridButtonColumn ButtonType="ImageButton" CommandName="Delete" ConfirmDialogType="RadWindow" ConfirmText="Are You Sure To Delete ?" ConfirmTitle="Delete" HeaderButtonType="None" HeaderText="Delete" Text="Delete" UniqueName="DeleteCommandColumn"> <HeaderStyle HorizontalAlign="Center" Width="50px" /> <ItemStyle HorizontalAlign="Center" /> </telerik:GridButtonColumn> <telerik:GridNumericColumn DataField="bqmiItemCode" DataType="System.Int32" HeaderText="Item Code" UniqueName="bqmiItemCode"> <HeaderStyle HorizontalAlign="Center" Width="75px" /> <ItemStyle HorizontalAlign="Left" /> </telerik:GridNumericColumn> <telerik:GridBoundColumn DataField="bqmiItemDescription" HeaderText="Description" UniqueName="bqmiItemDescription"> <HeaderStyle HorizontalAlign="Center" Width="150px" /> <ItemStyle HorizontalAlign="Left" /> </telerik:GridBoundColumn> <telerik:GridBoundColumn DataField="bqmiUnit" HeaderText="Unit" UniqueName="bqmiUnit"> <HeaderStyle HorizontalAlign="Center" Width="50px" /> <ItemStyle HorizontalAlign="Left" /> </telerik:GridBoundColumn> <telerik:GridNumericColumn DataField="bqmiPrice" DataType="System.Decimal" HeaderText="Price" NumericType="Currency" UniqueName="bqmiPrice" DefaultInsertValue="0"> <HeaderStyle HorizontalAlign="Center" Width="100px" /> <ItemStyle HorizontalAlign="Right" /> </telerik:GridNumericColumn> <telerik:GridNumericColumn DataField="bqmiQty" DataType="System.Decimal" HeaderText="Quantity" UniqueName="bqmiQty" DefaultInsertValue="0"> <HeaderStyle HorizontalAlign="Center" Width="100px" /> <ItemStyle HorizontalAlign="Right" /> </telerik:GridNumericColumn> <telerik:GridCalculatedColumn DataFields="bqmiPrice,bqmiQty" DataType="System.Decimal" Expression="{0}*{1}" HeaderText="Amount" UniqueName="bqmiAmount"> </telerik:GridCalculatedColumn> <telerik:GridDropDownColumn HeaderText="Drop" UniqueName="drop" DataField="drop" DefaultInsertValue="0"> </telerik:GridDropDownColumn> </Columns> <EditFormSettings> <EditColumn UniqueName="EditCommandColumn1"> </EditColumn> </EditFormSettings> </MasterTableView> <ClientSettings> <Scrolling AllowScroll="True" UseStaticHeaders="True" /> </ClientSettings> </telerik:RadGrid>

Protected Sub RadGrid1_ItemDataBound(ByVal sender As Object, ByVal e As GridItemEventArgs) Handles RadGrid1.ItemDataBound If TypeOf e.Item Is GridDataItem Then Dim item As GridDataItem = DirectCast(e.Item, GridDataItem) Dim id As String = item.GetDataKeyValue("CompanyID").ToString Dim CheckForWeb As Company CheckForWeb = Company.GetCompany(CInt(id)) ' see if the object is populated If CheckForWeb.CompanyID.HasValue Then ' check to see if there is a valid URL from the datafield WebsiteURL If CheckForWeb.WebsiteURL.Length > 10 Then item("CompanyWebsite").Text = "WEB" Else item("CompanyWebsite").Text = "" End If End If End If End SubProtected Sub RadGrid1_ItemDataBound(ByVal sender As Object, ByVal e As GridItemEventArgs) Handles RadGrid1.ItemDataBound If TypeOf e.Item Is GridDataItem Then Dim item As GridDataItem = DirectCast(e.Item, GridDataItem) Dim id As String = item.GetDataKeyValue("CompanyID").ToString Dim CheckForWeb As Company CheckForWeb = Company.GetCompany(CInt(id)) ' see if the object is populated If CheckForWeb.CompanyID.HasValue Then ' check to see if there is a valid URL from the datafield WebsiteURL If CheckForWeb.WebsiteURL.Length > 10 Then item("CompanyWebsite").Text = "WEB" Dim link As HyperLink = DirectCast(item("CompanyWebsite").Controls(0), HyperLink) link.NavigateUrl = CheckForWeb.WebsiteURL Else item("CompanyWebsite").Text = "" End If End If End If End Sub
I am new to telerik. I want rad grid to work as shown in screen shot. Please provide me solution…