Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
98 views
HI

I am using Rad Grid to display some data, i am running the site from  from a virtual directory, the grid loads fine but i cannot edit, delete or create new rows. after clicking on the edit link it just loads forever and nothing happens. Please assist me. it works fine if it';s not been run from a virtual directory.
Radoslav
Telerik team
 answered on 15 Feb 2010
9 answers
422 views

Hi,

Environment:
- Windows Vista with Service Pack1
- IIS 7
- RadControls for ASP.NET AJAX Q2 2009 NET35
- MS Visual Studio 2008

Error Message in Visual Studio Design Page:

 

Error Rendering Control - RadScriptManager1An unhandled exception has occurred.

Could not load file or assembly 'Telerik.Web.UI, Version=2009.2.701.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4' or one of its dependencies. The system cannot find the file specified.

_______________________________________________________________________________

I am creating a simple Website with just 1 page. Getting the above error message. I also can't register Telerik.Web.UI.WebResource.AXD from Visual Design Page because RadScriptManager Show Smart Tag is dimmed out, like read only.. In my Web Config File, I followed the instructions to register HTTPHandler from this Page.

http://www.telerik.com/help/aspnet-ajax/radscriptmanager.html

Below is my WEB Config, Default.aspx and Code Behind File. Please help. Thanks
________________

Web Config:

 


 

<?xml version="1.0"?>
<!--
    Note: As an alternative to hand editing this file you can use the
    web admin tool to configure settings for your application. Use
    the Website->Asp.Net Configuration option in Visual Studio.
    A full list of settings and comments can be found in
    machine.config.comments usually located in
    \Windows\Microsoft.Net\Framework\v2.x\Config
-->
<configuration>
 <configSections>
  <sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
   <sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
    <section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
    <sectionGroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
     <section name="jsonSerialization" type="System.Web.Configuration.ScriptingJsonSerializationSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="Everywhere"/>
     <section name="profileService" type="System.Web.Configuration.ScriptingProfileServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
     <section name="authenticationService" type="System.Web.Configuration.ScriptingAuthenticationServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
     <section name="roleService" type="System.Web.Configuration.ScriptingRoleServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
    </sectionGroup>
   </sectionGroup>
  </sectionGroup>
 </configSections>
 <appSettings/>
 <connectionStrings/>
 <system.web>
  <!--
            Set compilation debug="true" to insert debugging
            symbols into the compiled page. Because this
            affects performance, set this value to true only
            during development.
        -->
  <compilation debug="false">
   <assemblies>
    <add assembly="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    <add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    <add assembly="System.Data.DataSetExtensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    <add assembly="System.Xml.Linq, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    <add assembly="System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
    <add assembly="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    <add assembly="System.Drawing.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/></assemblies>
  </compilation>
  <!--
            The <authentication> section enables configuration
            of the security authentication mode used by
            ASP.NET to identify an incoming user.
        -->
  <authentication mode="Windows"/>
  <!--
            The <customErrors> section enables configuration
            of what to do if/when an unhandled error occurs
            during the execution of a request. Specifically,
            it enables developers to configure html error pages
            to be displayed in place of a error stack trace.

        <customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
            <error statusCode="403" redirect="NoAccess.htm" />
            <error statusCode="404" redirect="FileNotFound.htm" />
        </customErrors>
        -->
  <pages>
   <controls>
    <add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    <add tagPrefix="asp" namespace="System.Web.UI.WebControls" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
   </controls>
  </pages>
  <httpHandlers>
   <remove verb="*" path="*.asmx"/>
   <add verb="*" path="*.asmx" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
   <add verb="*" path="*_AppService.axd" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
   <add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false"/>
  </httpHandlers>
  <httpModules>
   <add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
  </httpModules>
 </system.web>
 <system.codedom>
  <compilers>
   <compiler language="c#;cs;csharp" extension=".cs" warningLevel="4" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
    <providerOption name="CompilerVersion" value="v3.5"/>
    <providerOption name="WarnAsError" value="false"/>
   </compiler>
   <compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" warningLevel="4" type="Microsoft.VisualBasic.VBCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
    <providerOption name="CompilerVersion" value="v3.5"/>
    <providerOption name="OptionInfer" value="true"/>
    <providerOption name="WarnAsError" value="false"/>
   </compiler>
  </compilers>
 </system.codedom>
 <!--
        The system.webServer section is required for running ASP.NET AJAX under Internet
        Information Services 7.0.  It is not necessary for previous version of IIS.
    -->
 <system.webServer>
  <validation validateIntegratedModeConfiguration="false"/>
  <modules>
   <remove name="ScriptModule"/>
   <add name="ScriptModule" preCondition="managedHandler" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
  </modules>
  <handlers>
   <remove name="WebServiceHandlerFactory-Integrated"/>
   <remove name="ScriptHandlerFactory"/>
   <remove name="ScriptHandlerFactoryAppServices"/>
   <remove name="ScriptResource"/>
   <add name="ScriptHandlerFactory" verb="*" path="*.asmx" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
   <add name="ScriptHandlerFactoryAppServices" verb="*" path="*_AppService.axd" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
   <add name="ScriptResource" preCondition="integratedMode" verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
   <add name="Telerik.Web.UI.WebResource" path="Telerik.Web.UI.WebResource.axd" verb="*" type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Version=2009.2.701.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4"/>
  </handlers>
 </system.webServer>
 <runtime>
  <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
   <dependentAssembly>
    <assemblyIdentity name="System.Web.Extensions" publicKeyToken="31bf3856ad364e35"/>
    <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
   </dependentAssembly>
   <dependentAssembly>
    <assemblyIdentity name="System.Web.Extensions.Design" publicKeyToken="31bf3856ad364e35"/>
    <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
   </dependentAssembly>
  </assemblyBinding>
 </runtime>
</configuration>

_________________

Defult.aspx

<%@ Page Language="C#" AutoEventWireup="true"  CodeFile="Default.aspx.cs" Inherits="_Default" %>

<%@ Register assembly="Telerik.Web.UI" 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">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
   
    </div>
    <telerik:RadScriptManager ID="RadScriptManager1" Runat="server">
    </telerik:RadScriptManager>
    </form>
</body>
</html>

____________
Code Behind:

 

using System;
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;

public partial class _Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
}

 

 

 

n gh
Top achievements
Rank 1
 answered on 15 Feb 2010
7 answers
122 views
Hi there,

I have the following scenario:

8 Editors on a page which all use the same Toolbar, so I implemented ToolProviderID so that all Editors use the Toolbar off the first Editor.

The toolbar is shown properly exept for the <symbols> section which shows the default list and not my custom defined list in the toolbar XML.

Any suggestions?

Marc
Debbie Roberts
Top achievements
Rank 1
 answered on 15 Feb 2010
1 answer
117 views
Hi Everybody,

I would like to crete new node on clientside and set this node to edit mode. And when user doesn't change the label and click outside, i would like show radalert and cancel postback -  so far so good. But after that I would like to set node to edit mode again. And I'm getting strange unhanded exceptions from code. This is my snippet:


function onClientNodeEditing(sender, eventArgs) { 
                var node = eventArgs.get_node(); 
                var oldText = node.get_text(); 
                var newText = eventArgs.get_newText() 
                var tree = $find("<%= ThreadRoot.ClientID %>"); 
                 
                if (newText == oldText) { 
                    radalert(Please change name of category!"); 
                    
                    tree.trackChanges(); 
                    node.startEdit(); 
                    tree.commitChanges(); 
 
 
                    eventArgs.set_cancel(true); 
                } 
            } 

Any ideas? for example this code returns Cannot set property 'onblur' of null (G Chrome) and stops execution with Uncaught RangeError, Maximum call stack size exceeded
Yana
Telerik team
 answered on 15 Feb 2010
3 answers
177 views
Im trying to create a dock zone, with 5 docks, and orientation horizontal, its a priority like utility, whats in the left its more important.

Problems:

    I cant set the height of each dock, another controls will be added inside. But, in firefox, these docks get very big. To reproduce this you just need a docklayout, a dockzone (no height), 2 docks inside (no height), and orientation horizontal. The docks dont feet to the content inside, but to the page height size (??). A workaround its to change the dock height when adding controls, but its very boring to do, im not sure how many text will come from database, and im not using a monospace font.

    I do need a space between each dock, what im trying to get adding a padding in the raddock_custom, and it works very bad, first because IE draw the help lines with padding, around and far from the dock, and FF seems to be adding the padding to the help lines and the virtual dock size each time a control is dragged around.

    In a dockzone without any width, the help lines dont show, and becomes impossible to drag docks, except the last one.

If anyone can point me a direction to solve these problems i ll be very glad.

Regards
Pero
Telerik team
 answered on 15 Feb 2010
1 answer
178 views
Hi guys.
here is my sqlcommand Code
<asp:SqlDataSource ID="SqlDataSource1" runat="server"  
            ConnectionString="<%$ ConnectionStrings:ConnectionString %>"  
          
            SelectCommand="SELECT AppointmentID, Start, [End], Subject, Due, Priority, UserID FROM Appointments_DragAndDrop WHERE (Start IS NOT NULL) AND ([End] IS NOT NULL) AND (UserID = @UserID)" 
            InsertCommand="INSERT INTO Appointments_DragAndDrop(Subject, Start, [End], UserID) VALUES (@Subject, @Start, @End , @UserID)" 
            UpdateCommand="UPDATE [Appointments_DragAndDrop] SET [Start] = @Start, [End] = @End, [Subject] = @Subject WHERE AppointmentID = @AppointmentID" 
             
             
            DeleteCommand="DELETE FROM [Appointments_DragAndDrop] WHERE [AppointmentID] = @AppointmentID"
            <InsertParameters> 
                <asp:Parameter Name="Subject" Type="String" /> 
                <asp:Parameter Name="Start" Type="DateTime" /> 
                <asp:Parameter Name="End" Type="DateTime" /> 
                <asp:Parameter Name="UserID"   /> 
            </InsertParameters> 
            <UpdateParameters> 
                <asp:Parameter Name="Start" Type="DateTime" /> 
                <asp:Parameter Name="End" Type="DateTime" /> 
                <asp:Parameter Name="Subject" Type="String" /> 
                <asp:Parameter Name="AppointmentID" Type="Int32" /> 
            </UpdateParameters> 
            <SelectParameters> 
                <asp:SessionParameter DefaultValue="" Name="UserID" SessionField="UserID" /> 
            </SelectParameters> 
            <DeleteParameters> 
                <asp:Parameter Name="AppointmentID" Type="Int32" /> 
            </DeleteParameters> 
        </asp:SqlDataSource> 
And here is code behinde
 private void HandleSchedulerDrop(int id, string subject, string targetSlotIndex) 
    { 
        RadScheduler1.Rebind(); 
 
        ISchedulerTimeSlot slot = RadScheduler1.GetTimeSlotFromIndex(targetSlotIndex); 
 
        TimeSpan duration = TimeSpan.FromHours(1); 
        if (slot.Duration == TimeSpan.FromDays(1)) 
        { 
            duration = slot.Duration; 
        } 
        
        ScheduleAppointment(id, subject, slot.Start, slot.Start.Add(duration), Session["UserID"].ToString()); 
    } 
 
    private void ScheduleAppointment(int id, string subject, DateTime start, DateTime end,string UserID) 
    { 
        IDataSource dataSource = SqlDataSource1; 
        DataSourceView view = dataSource.GetView("DefaultView"); 
 
        IOrderedDictionary data = new OrderedDictionary(); 
        data.Add("Subject", subject); 
        data.Add("Start", start); 
        data.Add("End", end); 
        data.Add("UserID", UserID); 
 
        IDictionary keys = new OrderedDictionary(); 
        keys.Add("AppointmentID", id); 
      
        view.Update(keys, data, new OrderedDictionary(), OnDataSourceOperationComplete); 
        
    } 
 
    private static bool OnDataSourceOperationComplete(int count, Exception e) 
    { 
        if (e != null
        { 
            throw e; 
        } 
        return true
    } 
How ican Insert? Insert occure right and okey! but UserID field is null!?
how i can fill UserID column in database with Session?
(Update Select and Delete Is absolutely okey)
tnx guys
Peter
Telerik team
 answered on 15 Feb 2010
1 answer
97 views
Hi,

I have a RadTreeView control which I have bound to the directory sctructure of a website very similar to Telerik's demo under Application Scenarios / Directory Structure found here. Anyway, what I'd like to do is when a user selects a page from the tree, I want to iterate through that page (not navigate to it) using reflection and list out the various controls available on the selected page in order to perform various administrative purposes. This is easy enough for User Controls as I can just use LoadControl to gain access to an instance of a user control and then reflect through it to pull out control references. But an actual  page is much different. I can't seem to find a way to either get a reference to the page in question or reflect the page. I think the nature of Partial Page Classes has something to do with it.

Anyway, if anyone has run into a similar issue, I'd love to hear how you worked around it.

Thanks in advance,
Tom
T. Tsonev
Telerik team
 answered on 15 Feb 2010
1 answer
111 views
Hello !
I use GridView to bound my data from Business layer.
I have some service:
BLProvinces and BLDistricts
I used GridView for displaying List<District> ( DistrictID,Name,ProvinceID).
but I did not want to display ProvinceID and...I used GridTemplateColumn:
 <telerik:GridTemplateColumn HeaderText="ProvinceName" SortExpression="????">         
        <ItemTemplate>            <%#BusinessLayer.BLProvinces.SelectRecordByID((long)Eval("ProvinceID")).Name%> 
        </ItemTemplate> 
        </telerik:GridTemplateColumn>  

I want to Sort ProvinceName  but I dont know what SortExpression ?
Help me! thanks your very much !.
Mai Van Binh
Top achievements
Rank 1
 answered on 15 Feb 2010
1 answer
111 views
Hi,

i have Problems with the RadAjaxManager:

1.) I have an Page that holds an AjaxManager
2.) I have (two) UserControls who call this AjaxManager to add AjaxSettings:
RadAjaxManager1.AjaxSettings.AddAjaxSetting(ButSchaetzen, ButOk, null); 
3.) When I rise an Event on the Button ButSchaetzen, then the Event is processed correctly, but the Control (ButOk) disappears from the UserControl.

When I try to search with the IE - DOM Explorer then I see the following:

 

document.getElementById('ruhestandcheck_UcRentenschaetzer1_ButOk').innerHTML 

Results in:

 

RADAJAX_HIDDENCONTROL

I can't figure out why this happens.
- In the Event of ButSchaetzen I set ButOk.Enable = true;
- Nothing else I do with the Button
- The same happens to all other Controls I added to the AjaxManager

The AjaxManager - HTML Code looks like this:
<radA:RadAjaxManager ID="RadAjaxManager1" runat="server" OnAjaxRequest="RadAjaxManager1_AjaxRequest" EnablePageHeadUpdate="false"   
          ClientEvents-OnRequestStart="requestStart()" ClientEvents-OnResponseReceived="responseReceived()" ClientEvents-OnResponseEnd="responseEnd()" 
          DefaultLoadingPanelID="AjaxLoadingPanel1">  
              <AjaxSettings > 
              </AjaxSettings>             
          </radA:RadAjaxManager> 

What can be the Reason why the AjaxManager set the Controls to "RADAJAX_HIDDENCONTROL"?

Regards

Volker Weg
Top achievements
Rank 1
 answered on 15 Feb 2010
2 answers
80 views
ComboBox renders incorrectly on IE8, but fine on FF. Items box seems slide 10px to left and about 15px up
And also there is a design time problem. It shows another arrow.
Please see attached files.



There is no style on page, just script manager and combobox.
Version is : 2009.3.1401.35

Any ideas?






Veselin Vasilev
Telerik team
 answered on 15 Feb 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?