Telerik Forums
UI for ASP.NET AJAX Forum
0 answers
149 views
I want sample code to sending sms through way2sms/fullonsms
pls help me......
NA
Top achievements
Rank 1
 asked on 14 May 2014
1 answer
120 views
Is it possible to use the poster when a video is not playing as place holder?

The poster shows up in playlist but I would like it also to be in place when the play button is shown.

Markus
Eyup
Telerik team
 answered on 14 May 2014
1 answer
244 views
When using combobox with RenderMode="Lightweight" and DropDownAutoWidth="Enabled" it renders two vertical scrollbars.

E.g. see attached image for the code below (data source is Dictionary<string,string>)
<telerik:RadComboBox ID="rcbCountry" runat="server"
    AppendDataBoundItems="true"
    DataSourceID="CountriesDataSource" DataTextField="Value" DataValueField="Key"
    Width="100px" DropDownAutoWidth="Enabled"
    RenderMode="Lightweight">
    <Items>
        <telerik:RadComboBoxItem Text="All" />
    </Items>
</telerik:RadComboBox>
Aneliya Petkova
Telerik team
 answered on 14 May 2014
1 answer
69 views
Currently radGrid doesn't provide paging based on visual (not collapsed) rows. E.g. go to http://demos.telerik.com/aspnet-ajax/grid/examples/functionality/grouping/grouping/defaultcs.aspx, collapse all 3 "Received" groups and radGrid show three rows only but pager reads "Item 1 to 20 of 52". Thus, if there are many groups then there is no way to see other groups on the current page by collapsing them - the only way is to go to another page which pretty inconvenient and annoying.

I'd like to have functionality similar to http://demos.devexpress.com/ASPxgridviewDemos/GroupingSorting/Grouping.aspx - try to collapse countries.

Do you have a workaround to achieve that or any plans to implement this feature?
Radoslav
Telerik team
 answered on 14 May 2014
1 answer
63 views
Hi 
  I want my dropdowntree depth level are configurable means if fixed DropDownTree depth level equals =2 then
DropDownTree  populates only level 2 only higher level nodes are disabled.How can I achieved this..
Plamen
Telerik team
 answered on 14 May 2014
1 answer
568 views
I have a radgrid and since I have custom buttons, I am using the CommandItemTemplate. But it throws "Cannot set property 'control' of undefined" error! When I comment out this._RadGrid1.MasterTableView.CommandItemDisplay = GridCommandItemDisplay.Top; It does not throw the error and ofcourse the CommandItemTemplate is also not visible.
protected override void OnInit(EventArgs e)
        {
            base.OnInit(e);
            
            this._RadLoadingPanel.ID = "_RadLoadingPanel";
            this._RadLoadingPanel.Transparency = 30;
            this._RadLoadingPanel.Skin = "WebBlue";
            this._RadLoadingPanel.BackgroundPosition = AjaxLoadingPanelBackgroundPosition.Center;
       
            this._RadGrid1.Skin = "WebBlue";
            this._RadGrid1.Width = Unit.Percentage(100);
            this._RadGrid1.GridLines = GridLines.None;
            this._RadGrid1.PageSize = 20;
            this._RadGrid1.AllowPaging = true;
            this._RadGrid1.PagerStyle.Mode = GridPagerMode.NextPrevAndNumeric;
            this._RadGrid1.AllowSorting = true;
            this._RadGrid1.AllowFilteringByColumn = false;
            this._RadGrid1.AllowAutomaticUpdates = false;
            this._RadGrid1.AutoGenerateColumns = false;
 
            this._RadGrid1.EnableLinqExpressions = false;
            this._RadGrid1.MasterTableView.NoMasterRecordsText = "No Deals found";
            this._RadGrid1.ShowGroupPanel = false;
            this._RadGrid1.ShowStatusBar = true;
            this._RadGrid1.GroupingEnabled = false;
 
            this._RadGrid1.ClientSettings.Selecting.AllowRowSelect = true;
            this._RadGrid1.ClientSettings.EnableRowHoverStyle = true;
            this._RadGrid1.ClientSettings.EnablePostBackOnRowClick = true;
            this._RadGrid1.MasterTableView.CommandItemDisplay = GridCommandItemDisplay.Top;
                //add buttons
            this._RadGrid1.MasterTableView.CommandItemTemplate = new DealTemplate(this._RadGrid1, "State");                             
 
            this._RadGrid1.MasterTableView.DataKeyNames = "PriceID";
            this._RadGrid1.MasterTableView.ClientDataKeyNames = "Status";
            this._RadGrid1.MasterTableView.EnableHeaderContextMenu = true;
 
            this._RadGrid1.MasterTableView.CommandItemSettings.ShowAddNewRecordButton = true;
            this._RadGrid1.ClientSettings.ClientEvents.OnRowSelected = "OnRowSelected";           
           
            this._RadGrid1.NeedDataSource += RadGrid1_NeedDataSource;
            this._RadGrid1.ItemDataBound += RadGrid1_ItemDataBound;
   
             #region Columns
}
Princy
Top achievements
Rank 2
 answered on 14 May 2014
3 answers
78 views
How do I add column which is updated using code and can be sortable?
I have RadGrid, which get the data using Entities Framework query.
I added label (lblTest1) to get additional information which isn't returned by the query, but in this way the column isn't sortable (because it's not one of the query outcomes).
Is there a different way to update the column so it will be sortable using the field data or is there a way to sort according to this label?

aspx:

<telerik:RadGrid ID="RadGrid1" runat="server" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" CellSpacing="0" 
DataSourceID="ObjectDataSourceIems" OnItemDataBound="RadGrid1_OnItemDataBound" GridLines="None" >
    <MasterTableView DataSourceID="ObjectDataSourceItems" 
        <CommandItemSettings ExportToPdfText="Export to PDF"></CommandItemSettings>
        <RowIndicatorColumn Visible="True" FilterControlAltText="Filter RowIndicator column">
            <HeaderStyle Width="20px"></HeaderStyle>
        </RowIndicatorColumn>
        <ExpandCollapseColumn Visible="True" FilterControlAltText="Filter ExpandColumn column">
            <HeaderStyle Width="20px"></HeaderStyle>
        </ExpandCollapseColumn>
        <Columns>
            <telerik:GridBoundColumn DataField="ItemID" FilterControlAltText="ItemID" HeaderText="ItemID" SortExpression="ItemID" UniqueName="ItemID">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="FirstName" FilterControlAltText="First Name" HeaderText="First Name" SortExpression="FirstName" UniqueName="FirstName">
           </telerik:GridBoundColumn>
            <telerik:GridTemplateColumn HeaderText="Test1" SortExpression="" UniqueName="Test1">                                
                <ItemTemplate>
                    <asp:Label ID="lblTest1" runat="server" Text="" />
                </ItemTemplate>
            </telerik:GridTemplateColumn>    
        </Columns>
        <EditFormSettings>
            <EditColumn FilterControlAltText="Filter EditCommandColumn column"></EditColumn>
        </EditFormSettings>
        <PagerStyle PageSizeControlType="RadComboBox"></PagerStyle>
    </MasterTableView>
    <PagerStyle PageSizeControlType="RadComboBox"></PagerStyle>
    <FilterMenu EnableImageSprites="False"></FilterMenu>
</telerik:RadGrid>

<asp:ObjectDataSource ID="ObjectDataSourceIems" runat="server" SelectMethod="GetItemsPaged"
    SelectCountMethod="GetObjectDataSourceIemsByNameCount"
    TypeName="test.BLL.Items.ItemsRepsitory" EnablePaging="True" SortParameterName="sortExpression">
    <SelectParameters>
        <asp:ControlParameter ControlID="TextBoxSearchString" Name="nameSearchString" PropertyName="Text" Type="String" />
        <asp:ControlParameter ControlID="RadioButtonListColumns" Name="searchColumn" PropertyName="SelectedValue" Type="String" />
    </SelectParameters>
</asp:ObjectDataSource>

cs:
public void RadGrid1_OnItemDataBound(object sender, GridItemEventArgs e)
{
    if (e.Item.ItemType != GridItemType.Item && e.Item.ItemType != GridItemType.AlternatingItem) return;
    var item = (Item)e.Item.DataItem;

    MoreInfoRepository moreInfoRepository = new MoreInfoRepository();
    MoreInfo moreInfo = moreInfoRepository.GetMoreInfo(item.ItemID);
    if (moreInfo != null)
    {
        var lblTest1 = (Label)e.Item.FindControl("lblTest1");
        lblTest1.Text = moreInfo.Test1;
    }
}
Princy
Top achievements
Rank 2
 answered on 14 May 2014
7 answers
247 views
Hi,

we have encountered a problem with the GridCalculatedColumn and EnableLinqExpressions = false where we receive an Exception on every PageLoad


Minimal Test Case: 

<telerik:RadGrid ID="RadGrid1" DataSourceID="XmlDataSource1" runat="server" Width="990px"
    EnableLinqExpressions="False">
    <MasterTableView AutoGenerateColumns="False">
        <Columns>
            <telerik:GridBoundColumn runat="server" UniqueName="value1" DataField="value1" HeaderText="Value 1" />
            <telerik:GridBoundColumn runat="server" UniqueName="value1" DataField="value1" HeaderText="Value 2" />
            <telerik:GridCalculatedColumn runat="server" Expression="value1 + value2" />
        </Columns>
    </MasterTableView>
</telerik:RadGrid>
<asp:xmldatasource id="XmlDataSource1" runat="server" datafile="Source.xml" xpath="DataPoints/Point"/>

source.xml
<?xml version="1.0" encoding="utf-8" ?>
<DataPoints>
  <Point Value1="1" Value2="2"/>
</DataPoints>


This yields the Exception:

Server Error in '/Example' Application.

Cannot remove this column, because it is part of an expression: column = value1 + value2.

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. 

Exception Details: System.ArgumentException: Cannot remove this column, because it is part of an expression: column = value1 + value2.

Source Error: 

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace: 

[ArgumentException: Cannot remove this column, because it is part of an expression: column = value1 + value2.]
   System.Data.DataColumnCollection.CanRemove(DataColumn column, Boolean fThrowException) +1865260
   System.Data.DataColumnCollection.BaseRemove(DataColumn column) +25
   System.Data.DataColumnCollection.Remove(DataColumn column) +53
   Telerik.Web.UI.GridDataTableFromEnumerable.GetColumnsToUse() +6962
   Telerik.Web.UI.GridDataTableFromEnumerable.FillData() +661
   Telerik.Web.UI.GridResolveEnumerable.Initialize() +32
   Telerik.Web.UI.GridResolveEnumerable.EnsureInitialized() +20
   Telerik.Web.UI.GridEnumerableFromDataView..ctor(GridTableView owner, IEnumerable enumerable, Boolean CaseSensitive, Boolean autoGenerateColumns, GridColumnCollection presentColumns, String[] additionalField, Boolean retrieveAllFields, Boolean enableSplitHeaderText) +163
   Telerik.Web.UI.GridDataSourceHelper.CreateGridEnumerable(GridTableView owner, IEnumerable enumerable, Boolean caseSensitive, Boolean autoGenerateColumns, GridColumnCollection presentColumns, String[] additionalField, Boolean retrieveAllFields, Boolean enableSplitHeaderText) +129
   Telerik.Web.UI.GridDataSourceHelper.GetResolvedDataSource(GridTableView owner, Object dataSource, String dataMember, Boolean caseSensitive, Boolean autoGenerateColumns, GridColumnCollection presentColumns, String[] additionalField, Boolean retrieveAllFields, Boolean enableSplitHeaderText) +398
   Telerik.Web.UI.GridTableView.get_ResolvedDataSource() +159
   Telerik.Web.UI.GridTableView.CreateControlHierarchy(Boolean useDataSource) +316
   Telerik.Web.UI.GridTableView.CreateChildControls(IEnumerable dataSource, Boolean useDataSource) +550
   System.Web.UI.WebControls.CompositeDataBoundControl.PerformDataBinding(IEnumerable data) +57
   System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable data) +114
   System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +31
   System.Web.UI.WebControls.DataBoundControl.PerformSelect() +142
   Telerik.Web.UI.GridTableView.PerformSelect() +16
   System.Web.UI.WebControls.BaseDataBoundControl.DataBind() +73
   Telerik.Web.UI.GridTableView.DataBind() +229
   Telerik.Web.UI.RadGrid.DataBind() +80
   System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound() +82
   System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls() +72
   System.Web.UI.Control.EnsureChildControls() +87
   System.Web.UI.Control.PreRenderRecursiveInternal() +44
   System.Web.UI.Control.PreRenderRecursiveInternal() +171
   System.Web.UI.Control.PreRenderRecursiveInternal() +171
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +842



Using Telerik Q2-2012-SP2 (2012.2.912.35)
Peter
Top achievements
Rank 1
 answered on 14 May 2014
1 answer
80 views
Hi Guys,

I am experiencing the following problem:
I created my custom paragraph style "Small" for the FormatBlock Dropdown. It wraps text in <smal> tag and works as as expected.
However after applying this paragraph style it is not replaced with the <h1> etc. default styles when I choose them in the dropdown.
Steps to reproduce:
1. Put any text to the editor. For example: Test
2. Select it and click on the custom "Small" style in the FormatBlock Dropdown.
     Result in the HTML view: <small>Test</small>.
3. Select the word again and click Heading 1 default style.
    Result in the HTML view: <h1><small>Test</small></h1>.

On the other hand when I choose Heading 1, Heading 2, Menu etc. default styles successively, the current value replaces the old one:
<h1>Test</h1>  =>  <h2>Test</h2>  =>  <menu>Test</menu>  => ...

Is this an expected behavior with the custom  paragraph style or not?
Can you offer how to fix this issue in some simple way?

Best Regards,
Yuriy
Ianko
Telerik team
 answered on 14 May 2014
3 answers
429 views

 how to disabled raddropdowntree on particular node level .means i want my raddropdowntree level are configurable
Shinu
Top achievements
Rank 2
 answered on 14 May 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?