Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
138 views
I have a radcombox with custom validator for checking if any item is selected in the list; I have virtual scrolling enabled. When I search for items containing some text, the items are populating in the combobox and if there are many items, the scroll bar is showing. When I select the scroll down arrow , the validation is getting triggered. Ideally it should not as I am just scrolling. The validation should only trigger when I do not select an item in the radcombobox and I lose control focus. Is this a bug in telerik?

<telerik:RadComboBox ID="ListSelect" runat="server" Width="192px" EnableLoadOnDemand="true"      ShowMoreResultsBox="true" EnableVirtualScrolling="true" WebServiceSettings-Path="../../ws/AutoSuggest/AutoSuggest.asmx"  AllowCustomText="true" Filter="Contains" OnClientItemsRequesting="SearchAutoSuggest"      WebServiceSettings-Method="GetResults" OnClientSelectedIndexChanged="SelectAutoSuggestValue" AutoPostBack="false" MaxHeight="400px" OnClientDropDownOpening="selectText" MarkFirstMatch="true"  OnClientItemsRequested="highlightText" OnClientDropDownOpened="highlightText"   >
  </telerik:RadComboBox>
                              
                                <asp:CustomValidator ID="Validator_PatientGroupSelect" runat="server" ControlToValidate="ListSelect" ClientValidationFunction="checkValidSelection" />
Dimitar Terziev
Telerik team
 answered on 16 Jul 2012
7 answers
191 views
I've got a treelist with 7 columns, the first one has the check selector, the second one is a TreeListBoundColumn and the others are TreeListTemplateColumn between date fields, comboboxes and numeric text boxes, I PRESS THE ADD BUTTON ('plus icon' given by the treelist template) and fill the data, HOW CAN I GET THE DATA I JUST PUT IN THE FIELDS (specially the templates) TO INSERT THEM IN DATABASE WHEN I PRESS THE SAVE ICON (check icon)?
THANKS IN ADVANCE

This is my tree list code:

<telerik:RadTreeList ID="tasksListRadTreeList" runat="server" Width="100%"

                DataKeyNames="IdTask"

                ParentDataKeyNames="IdFather" AutoGenerateColumns="False"

                EditMode="InPlace" AllowPaging="False"

              

                oneditcommand="tasksListRadTreeList_EditCommand"

                oninsertcommand="tasksListRadTreeList_InsertCommand" 

                onneeddatasource="tasksListRadTreeList_NeedDataSource"

                onitemdatabound="tasksListRadTreeList_ItemDataBound">

                        <Columns>

                            <telerik:TreeListSelectColumn HeaderStyle-Width="38px">

                            </telerik:TreeListSelectColumn>

                                        

                            <telerik:TreeListBoundColumn DataField="NameTask" HeaderText="Title" UniqueName="NameTask" SortExpression="NameTask" HeaderStyle-Width="30%" />

                            <telerik:TreeListTemplateColumn HeaderText="Start Date" DataField="StartDate" UniqueName="StartDate" SortExpression="StartDate" HeaderStyle-Width="80px">

                            <ItemTemplate>

                                <asp:Label ID="label3" runat="server" Text='<%# Eval("StartDate") %>' ToolTip='<%# Eval("EndDate") %>'></asp:Label>

                            </ItemTemplate>

                            <EditItemTemplate>

                                <telerik:RadDatePicker ID="startDateRadDatePicker1" Runat="server" SelectedDate='01/01/2012' Width="80" Calendar-CultureInfo="es-CO" Calendar-DateRangeSeparator=" /">

                                </telerik:RadDatePicker>

                            </EditItemTemplate>

                            </telerik:TreeListTemplateColumn>

                            <telerik:TreeListTemplateColumn HeaderText="End Date" DataField="EndDate" UniqueName="EndDate" SortExpression="EndDate" HeaderStyle-Width="80px">

                            <ItemTemplate>

                                <asp:Label ID="label4" runat="server" Text='<%# Eval("EndDate") %>' ToolTip='<%# Eval("EndDate") %>'></asp:Label>

                            </ItemTemplate>

                            <EditItemTemplate>

                                <telerik:RadDatePicker ID="endDateRadDatePicker" Runat="server" SelectedDate='01/01/2012' Width="80">

                                </telerik:RadDatePicker>

                            </EditItemTemplate>

                            </telerik:TreeListTemplateColumn>                                                    

                            <telerik:TreeListTemplateColumn HeaderText="Priority" DataField="Priority" UniqueName="Priority" SortExpression="Priority" HeaderStyle-Width="60px">

                            <ItemTemplate>

                                <asp:Label ID="label5" runat="server" Text='<%# Eval("Priority") %>' ToolTip='<%# Eval("Priority") %>'></asp:Label>

                            </ItemTemplate>

                            <EditItemTemplate>

                                <telerik:RadComboBox ID="priorityRadComboBox" CheckBoxes="True" ShowDropDownOnTextboxClick="True" runat="server" Culture="es-CO" Width="60px"></telerik:RadComboBox>

                            </EditItemTemplate>

                            </telerik:TreeListTemplateColumn>

                            <telerik:TreeListTemplateColumn HeaderText="% " DataField="Percentage" UniqueName="Percentage" SortExpression="Percentage" HeaderStyle-Width="50px">

                            <ItemTemplate>

                                <asp:Label ID="label6" runat="server" Text='<%# Eval("Percentage") %>' ToolTip='<%# Eval("Percentage") %>'></asp:Label>

                            </ItemTemplate>

                            <EditItemTemplate>

                                <telerik:RadNumericTextBox ID="percentRadNumericTextBox" runat="server" Text='<%# Eval("Percentage") %>' Width="50" MaxLength="3" MaxValue="100" MinValue="0" ShowButton="False" ShowSpinButtons="True"></telerik:RadNumericTextBox>

                            </EditItemTemplate>

                            </telerik:TreeListTemplateColumn>

                           <telerik:TreeListEditCommandColumn UniqueName="EditCommandColumn" ButtonType="ImageButton" ShowAddButton="True" HeaderStyle-Width="70px" AddRecordText="Agregar Subtarea" CancelText="Cancelar" EditText="Editar Tarea">

                                <ItemStyle CssClass="MyImageButton" />

                            </telerik:TreeListEditCommandColumn>

                        </Columns>

            </telerik:RadTreeList>

            </telerik:RadAjaxPanel>


Andrey
Telerik team
 answered on 16 Jul 2012
1 answer
210 views
Hi there,
   For a ASP.NET project we are working on, we need to have the capability of generate Telerik control HTML in server side code and then return the controls's html to front-end via client script for dynamic replacement. 
   We have been unsuccessful in getting Telerik control HTML output via server side code and wondering if everyone have had similar experience can share some knowledge and solutions. 

   Please refer to the code below on how we are trying to get Telerik control HTML output:

StringWriter tw = new StringWriter(sb);
HtmlTextWriter hw = new HtmlTextWriter(tw);
Telerik.Web.UI.RadComboBox rcb = new Telerik.Web.UI.RadComboBox();
rcb.ID = "sokmething";
rcb.RenderControl(hw);   // Freeze here during execution
string b = tw.ToString();
Ivana
Telerik team
 answered on 16 Jul 2012
1 answer
92 views
Hi!

I have a RadGrid control on page with 100% width.
When vertical scroll appears on the grid, its extends page width with scrollbar's width. In this case the column's header and item style width is the same.
I use tablelayout:fixed property in mastertableview. If I don't use this property the problem is still exists.

If I put the radgrid in a table with table-layout:fixed, its doesn't extend page, but the column's header and item style width not the same.

How should I resolve this issue?
Thanks
Princy
Top achievements
Rank 2
 answered on 16 Jul 2012
1 answer
297 views
I am trying to create a page that will display a dynamic set of results based on user input.  The gist is that the results will look something would contain specific info about a customer site, followed by a grid with the detailed results for that particular location.  Something like:

Site: sitename, city, state
    grid w/ satisfaction survey results

The user would be able to pick either a single site, all of the sites that reports to them, or to a subset.  Since this is a dynamic list, I thought it would be best to use a user control with the grid.  I already have a datatable that has the results for all of the selected sites, so I want to pass the datatable to the user control, then let the control apply a filter.

So I created a user control, and the code-behind for it looks like:

namespace SurveyResults
{
  public partial class resultsGrid : System.Web.UI.UserControl
  {
    private DataTable _dtResults = null;
 
    public DataTable dtResults
    {
      get
      {
        return _dtResults;
      }
      set
      {
        _dtResults = dtResults;
      }
    }
 
    protected void Page_Load(object sender, EventArgs e)
    {
        gridResults.DataSource = _dtResults;
        gridResults.Rebind();
    }
  }
}


Then I added a placeholder to my primary page, and added the following code:

// dtResults is a datatable that contains the results for all sites.  I have verified that it does contain data at this point
 
_resultsGrid = (resultsGrid)Page.LoadControl("resultsGrid.ascx");
_resultsGrid.dtResults = dtResults;
phResults.Controls.Add(_resultsGrid);

When I set a breakpoint on the set property for dtResults, I am only getting a null value.  So then when the page_load for the user control runs, the datasource is null.  I don't get an error, I just don't get a grid either.

I will be very much appreciative if someone can point out what it is that I am doing wrong here.

Thank you!
Andrey
Telerik team
 answered on 16 Jul 2012
3 answers
170 views
Hi all,

In my datagrid, I need to generate an automatic date picker on the addnewrecord command. How can I do this?

Thanks in advance
Princy
Top achievements
Rank 2
 answered on 16 Jul 2012
3 answers
115 views
I am using the RadSchedular for our application. All the data are coming,saving and updating through Web service which the Telerik project provided. I only changed the business logic in the MyDbSchedulerProvider class to get and save data from our database. There are lots of cases when service side error can occur. However I am unable to throw the error from web method to the Schedular pages . Can anyone please help me in this regard?
Plamen
Telerik team
 answered on 16 Jul 2012
2 answers
113 views
Hi all,


I have a Rad Binary Image.. i wish to the binary image control work as a hyper link..
please help

Regards,

Prassin
Prassin
Top achievements
Rank 1
 answered on 16 Jul 2012
11 answers
261 views
Hello,

in my project I have big troubles with the rendering of the RadDatePicker. It seems the CSS is not applied (well) to the control. Instead of the calendar button, the tooltip is rendered as hyperlink for opening the calendar. When the calendar, for date selection, is opened there's no background etc.
The RadDatePicker is on a RadMultiPage in a UserControl that is set to visibele after clicking a button in the NamingContainer (in the sampel a aspx but in my project also a UserControl) of the UserControl. The UserControl has a RadAjaxPanel on it which contains the RadDatePicker, the NamingContainer als has a RadAjaxPanel.

I've tried to reproduce the problem in a sample project which I've attached. Only in this sample te problem appears after clicking/changing the tabstrip a few times while in my application the problem always appears.

Hopefully there's someome who can help me with this problem.

Regards,
    Jos Meerkerk

Default.aspx:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="RadDatePicker.Default" %>
 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<%@ Register TagPrefix="uc" TagName="DatePicker" Src="~/DatePicker.ascx" %>
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 
<head runat="server">
    <title></title>
</head>
 
<body>
    <form id="form1" runat="server">
    <div  style="margin-left:100px;margin-top:100px;">
        <telerik:RadScriptManager ID="RadScriptManager1" runat="server"></telerik:RadScriptManager>
        <telerik:RadButton ID="RadButton1" runat="server" Text="RadButton"
            onclick="RadButton1_Click">
        </telerik:RadButton> <br />
        <uc:DatePicker ID="ucDatePicker" runat="server"  Visible="false" />
    </div>
    </form>
</body>
</html>

Default.aspx.cs:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
 
namespace RadDatePicker
{
    public partial class Default : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
 
        }
 
        protected void RadButton1_Click(object sender, EventArgs e)
        {
            ucDatePicker.Visible = true;
        }
    }
}

DatePicker.ascx:
<telerik:RadAjaxPanel ID="rapPanel" runat="server">
<telerik:RadTabStrip ID="RadTabStrip1" runat="server"
    MultiPageID="RadMultiPage1" Skin="Windows7" AutoPostBack="true">
    <Tabs>
        <telerik:RadTab runat="server" PageViewID="rpvPage1" Text="Root RadTab1">
        </telerik:RadTab>
        <telerik:RadTab runat="server" PageViewID="rpvPage2" Text="Root RadTab2">
        </telerik:RadTab>
        <telerik:RadTab runat="server" PageViewID="rpvPage3" Text="Root RadTab3">
        </telerik:RadTab>
    </Tabs>
</telerik:RadTabStrip>
<telerik:RadMultiPage ID="RadMultiPage1" Runat="server" RenderSelectedPageOnly="true" EnableEmbeddedScripts="true" SelectedIndex="0">
    <telerik:RadPageView ID="rpvPage1" runat="server">
        RadPageView Page 1
    </telerik:RadPageView>
    <telerik:RadPageView ID="rpvPage2" runat="server">
        RadPageView Page 2<br />
        <telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server">
            <telerik:RadDatePicker ID="RadDatePicker2" runat="server" Skin="Windows7">
            </telerik:RadDatePicker>
        </telerik:RadAjaxPanel>
    </telerik:RadPageView>
    <telerik:RadPageView ID="rpvPage3" runat="server">
        RadPageView Page 3
    </telerik:RadPageView>
</telerik:RadMultiPage>
 
</telerik:RadAjaxPanel>

RvdGrint
Top achievements
Rank 1
 answered on 15 Jul 2012
0 answers
117 views
Hi

I have persistStateInCookie = true so that visitors can know where they are when navigating pages.
But I want to be able to close all expanded menu items when the visitor returns to the home page.

Right now, any item that was expanded remains open when the visitor returns to the Home page which is
somewhat confusing.

Can anyone help?

I have tried numerous ways of expiring the cookie, but nothing works so far.

Thanks for help!

Clive
Clive Hoggar
Top achievements
Rank 1
 asked on 14 Jul 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?