Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
52 views
I discovered that no class is applied to an image when the image is selected and the class is applied through the "Apply CSS class" dropdown on the toolbar. This is happening in IE9, in FireFox (4.0.1) it works OK.
I have tested it in the First Look demo on the telerik website...

BR,
Marc
Rumen
Telerik team
 answered on 12 May 2011
1 answer
110 views
Hi,

We are already using script combine from ScriptManater, which works fine.

Does Telerik RadScriptManager or any other class provides minimizing scripts and css files?

Thanks,

Gopi
Simon
Telerik team
 answered on 12 May 2011
2 answers
575 views
Hi everyone,

I want to know if it's possible to change the datasource of a grid. The reason is that I used a listbox and I want that, when someone click on a item in the listbox, the grid automatically show the data associated with the item. But each item contains differents data. Can someone helps me ?

Ps : If it can help you, I want to create something that similiar to a file explorer.
David
Top achievements
Rank 1
 answered on 12 May 2011
1 answer
119 views
I'd like to be able to make the contents only of a panel item disabled or read/view only. Basically so the panel items can still be expanded/collapsed but its ContentTemplate contents cannot be edited.

 Is this possible?  Simply disabling the panelitem make it so you cannot expand/collapse anymore.

Lookin' for something like either a simple attribute to do this or some sample code on how to properly loop through a panelbar's contents (i.e. asp panels) to set their enable property to false. And/or any tips/hints.

Thanks.


Dimitar Terziev
Telerik team
 answered on 12 May 2011
1 answer
179 views
Hi,
I have a radtreeview control on my aspx page. The treeview control is populated from a dataset on selectedindex_change event of a combobox control through asynchrounous postback.

I have a text box in which the user enters a string, based on the string entered the nodes which contain the string in their text must only be displayed. eg:- if(treeview.node[i].text.contains(textbox.text))
                            {
                                display node........
                            }
                            else
                            {
                                node.visible=false;
                            }
To achieve this I have a textbox onkeypress event. But whenever i try "treeview.AllNodes.length" in my javascript it gives me null.
Kindly guide me through.

Thanks.
Kate
Telerik team
 answered on 12 May 2011
1 answer
27 views
Can we apply Styles from TelerikStyleBuilder to a ASP.NET gridview?
Princy
Top achievements
Rank 2
 answered on 12 May 2011
2 answers
102 views
Hello,
When I open a Radwindow with "radopen" function and "autoSize",
The first time the window is opened, It's Ok. but when I use the "Ok" button, there is some scroll which appears.

Here is an example.

Perhaps you can help me ?
Manys thanks.
Bernard

Telerik.js
<!--
// Pop up
var XPupVal_Ok = "XPup1";
var XPupVal_Annuler = "XPup0";
function XPupAdjust() 
    setTimeout(function(){XPupGetWin().autoSize(true)}, 500);
}
function XPupGetWin()
{
    var oWindow = null;
    if (window.radWindow) oWindow = window.radWindow;
        else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow;
    return oWindow;
}
  
function XPupOk()
{
    XPupGetWin().close(XPupVal_Ok);
}
function XPupAnnuler()
{
    XPupGetWin().close(XPupVal_Annuler);
}
function XPupClose(sender, args)
{
    if (args.get_argument() == XPupVal_Ok)
    {
        //some code
    };
}
-->

Telerik_Main.aspx

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Telerik_Main.aspx.cs" Inherits="Xarc.Telerik_Main" %>
  
<%@ Register Assembly="Telerik.Web.UI, Version=2010.3.1317.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4"
    Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
      
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head runat="server">
    <title>Page sans titre</title>
  
    <script type="text/javascript" src="Telerik.js"></script>
  
    <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
  
        <script type="text/javascript">
        function pageLoad() 
        {
  
        
        function ShowTelerik_Window()  
        {    
                                                                       
            function f()
            {
                Sys.Application.remove_load(f);
                window.radopen("Telerik_Window.aspx", "Telerik_Window");  
            }
            Sys.Application.add_load(f);
        }
        </script>
  
    </telerik:RadCodeBlock>
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
    </telerik:RadScriptManager>
    <div>
        <telerik:RadToolBar ID="toolBar" runat="server" BackColor="White" Width="100%" AutoPostBack="True"
            OnButtonClick="toolBar_ButtonClick">
            <Items>
                <telerik:RadToolBarButton runat="server" ToolTip="Window Open" Value="LOC" Text="OpenRadW">
                </telerik:RadToolBarButton>
            </Items>
        </telerik:RadToolBar>
    </div>
    <telerik:RadWindowManager runat="server" RestrictionZoneID="offsetElement" ID="XPupWindowManager"
        EnableShadow="true" ShowOnTopWhenMaximized="False" Behavior="Default" InitialBehavior="None"
        OnClientClose="XPupClose" Behaviors="None" Modal="true">
    </telerik:RadWindowManager>
    </form>
</body>
</html>

Telerik_Window.ASPX

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Telerik_Window.aspx.cs"
    Inherits="Xarc.Telerik_Window" %>
  
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head runat="server">
    <title>Page sans titre</title>
    <script type="text/javascript" src="Telerik.js"></script>
    <script type="text/javascript">
        function pageLoad() 
        {
            XPupAdjust(); 
        
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server" />
    <telerik:RadFormDecorator ID="RadFormDecorator1" runat="server" />
    <div style="height: 142px; width: 496px">
        <table style="width: 100%;">
            <tr>
                <td>
                    <asp:Label ID="LibLabel" runat="server"></asp:Label>
                </td>
                <td>
                    <asp:RequiredFieldValidator ID="RFV" runat="server" Display="Dynamic" ErrorMessage="Libellé obligatoire"
                        ControlToValidate="Lib" SetFocusOnError="True">*</asp:RequiredFieldValidator>
                </td>
                <td>
                    <asp:TextBox ID="Lib" runat="server" Width="336px"></asp:TextBox>
                </td>
            </tr>
        </table>
        <br />
        <asp:Button ID="MnuOk" runat="server" ToolTip="Validez" Text="Ok" OnClick="MnuOk_Click">
        </asp:Button>
        <asp:CustomValidator ID="CustomValidatorGeneral" runat="server" ErrorMessage="*"
            Display="Dynamic" ForeColor="White"></asp:CustomValidator>
        <input id="AnnBt" type="button" value="Annuler" onclick="XPupAnnuler();" />
        <div>
            <asp:ValidationSummary ID="ValidationSummary" runat="server" Width="100%"></asp:ValidationSummary>
        </div>
    </div>
    </form>
</body>
</html>

Telerik_Main.cs

using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using Telerik.Web.UI;
  
namespace Xarc
{
    public partial class Telerik_Main : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            //RadAjaxManager1.AjaxRequest += new RadAjaxControl.AjaxRequestDelegate(manager_AjaxRequest);
        }
        protected void toolBar_ButtonClick(object sender, Telerik.Web.UI.RadToolBarEventArgs e)
        {
            switch (e.Item.Value)
            {
                case @"LOC":
                    ScriptManager.RegisterStartupScript(this, GetType(), @"ShowTelerik_Window", @"ShowTelerik_Window();", true);
                    break;
            };
        }
        protected void manager_AjaxRequest(object sender, Telerik.Web.UI.AjaxRequestEventArgs e)
        {
            try
            {
                  
            }
            catch (Exception err)
            {
                 
            }
        }
    }
}

Telerik_Window.cs

using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using Telerik.Web.UI;
  
namespace Xarc
{
    public partial class Telerik_Window : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
  
        }
  
        protected void MnuOk_Click(object sender, EventArgs e)
        {
  
        }
    }
}
Stéphane
Top achievements
Rank 1
 answered on 12 May 2011
2 answers
44 views
When a multi-day appointment fires the AppointmentCreated event of the Scheduler, how can I tell what date the event has been fired for?

In other words, if I have an appointment scheduled for 5 days, it seems to fire the AppointmentCreated event 5 times.  The start/end dates are naturally the same, and I don't see a way to tell which date the event is being fired for.
Adrian Barnes
Top achievements
Rank 1
 answered on 12 May 2011
1 answer
206 views
Hi, i looked into the samples in doing this but here are some issues,

A) my custom controls have dropdownboxes that populated on the page load of the control. However this method causes the  Invalid attempt to call FieldCount when reader is closed error, when adding a new record.  How do i correct this that i dont get that error and i get the control loaded with data as i invoke it

B) i noticed that when using the custom control way, the control would cover the grid even with the Edit Mode set to EditForms, is there a way it can behave like the autogenerated editforms?

Thanks!




Elliott
Top achievements
Rank 2
 answered on 12 May 2011
1 answer
54 views
Hi , i'm student , i have some problem with ajax manager,when i click to btnclick button ,the code will run until RadGrid2.DataSource = qt.DanhSachDoiQua(makh); , but i must reload my site then
it updated into RadGrid2
 

 this's my code
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" Runat="server"
                   Skin="Default" >
               </telerik:RadAjaxLoadingPanel>
               <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"
                   DefaultLoadingPanelID="RadAjaxLoadingPanel1" EnableAJAX="true" >
                   <AjaxSettings >
                         <telerik:AjaxSetting  AjaxControlID="btnclick"  >
                           <UpdatedControls>                                  
                               <telerik:AjaxUpdatedControl ControlID="RadGrid2"   />                            
                           </UpdatedControls>
                       </telerik:AjaxSetting>                      
                   </AjaxSettings>
               </telerik:RadAjaxManager>
protected void btnclick_Click(object sender, EventArgs e)
{
    qt = new global::sieuthi.BUSINESS.B_quatang();
    foreach (GridDataItem item in RadGrid1.SelectedItems)
    {
        string strKey = "";
        string sl = "";
        //  TextBox tb = (TextBox)item.TemplateControl.FindControl("txtsl");//.GetDataKeyValue("txtsl").ToString();
        try
        {
            strKey = item.GetDataKeyValue("ID").ToString();
            sl = txtsoluong.Text.Trim();
            qt.addQuatang(makh, strKey, int.Parse(sl));
        }
        catch (Exception ex)
        {
            lbloi.Text = ex.Message;
            //khach2 hàng @KH đã có trong DS tặng quà cá»§a sá»± kiện @sukien Nam @nam ==>bo sung gap
        }
    }          
    RadGrid2.DataSource = qt.DanhSachDoiQua(makh);
}
Cori
Top achievements
Rank 2
 answered on 12 May 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?