Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
156 views
I am getting the following error when I deploy my application to our webserver.  I have Telerik version 2009.3 1103.  How do I resolve this issue?

Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Could not load file or assembly 'Telerik.Web.UI' or one of its dependencies. The system cannot find the file specified. (C:\Inetpub\wwwroot\TestApp\web.config line 113)

Source Error:

Line 111:		<httpModules>
Line 112:			<add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
Line 113:			<add name="RadUploadModule" type="Telerik.Web.UI.RadUploadHttpModule, Telerik.Web.UI" />
Line 114:			<add name="RadCompression" type="Telerik.Web.UI.RadCompression" />
Line 115:		</httpModules>

Source File: C:\Inetpub\wwwroot\TestApp\web.config    Line: 113


Daniel
Telerik team
 answered on 23 Dec 2009
1 answer
107 views
I have a RadComboBox that has a RadTreeView.  I would like to make the field required and am having a little trouble putting it together in my head.  I need to make sure that a non-root level node is selected in the tree.  Anyone have any advice on how to accomplish this?  I thinking that a RequiredFieldValidator is out of the question and I'll probably need to go the CustomValidator route. 
Any help appreciated.


Here is my markup:
<telerik:RadComboBox ID="ProjectRadComboBox" AllowCustomText="True" EmptyMessage="[Choose One...]" 
    runat="server" Width="150px">  
    <ItemTemplate> 
        <div onclick="StopPropagation(event)">  
            <telerik:RadTreeView ID="ProjectRadTreeView" runat="server" DataTextField="project_name" 
                DataValueField="project_id" DataFieldID="project_id" DataFieldParentID="fk_precinct_id" 
                OnClientNodeClicking="OnClientNodeClickingHandler" OnNodeExpand="ProjectRadComboBox_NodeExpand" 
                Height="300px">  
            </telerik:RadTreeView> 
        </div> 
    </ItemTemplate> 
    <Items> 
        <telerik:RadComboBoxItem runat="server" Text="[Choose One...]" Value="[Choose One...]" Selected="True" /> 
    </Items> 
</telerik:RadComboBox> 

Gene
Top achievements
Rank 1
 answered on 23 Dec 2009
3 answers
128 views
Hello,

I am trying to create a grid with 2-level self referencing hierarchy. However, the client does not have direct access to the database; it can only request a dataset for a given key. Is there any way to do this without looping through and loading the entire table into the dataset?

This is my current code (TCDataSet is inherited from the DataSet object):
protected void loadGrid() 
    { 
        // Get the null level type codes
        TCDataSet typeCodeDataset = controller.GetTypeCode(null); 
        DataView typeCodeDataview = typeCodeDataset.typecode.DefaultView; 

         
        // Bind the RadGrid's top level view to the null level type codes 
        RadGrid1.MasterTableView.DataSource = typeCodeDataview; 
        RadGrid1.MasterTableView.DataKeyNames = new string[] { "type_code" }; 
        RadGrid1.MasterTableView.EnableColumnsViewState = false
 
        // Create datasets for sub level typecodes 
        TCDataSet[] subTypeCodes = new TCDataSet[typeCodeDataview.Count]; 
        DataView[] subTypeCodeViews = new DataView[typeCodeDataview.Count]; 
        GridTableView[] subTypeCodeTableViews = new GridTableView[typeCodeDataview.Count]; 
        for (int i = 0; i < typeCodeDataview.Count; i++) 
        { 
            subTypeCodes[i] = new TCDataSet(); 
            subTypeCodeViews[i] = subTypeCodes[i].typecode.DefaultView; 
            subTypeCodeTableViews[i] = new GridTableView(); 
            subTypeCodeTableViews[i].DataSource = subTypeCodeViews[i]; 
            subTypeCodeTableViews[i].DataKeyNames = new string[2] { "type_code""type_value" }; 
            RadGrid1.MasterTableView.DetailTables.Insert(i, subTypeCodeTableViews[i]); 
            GridBoundColumn subColumn = new GridBoundColumn(); 
            RadGrid1.MasterTableView.DetailTables[i].Columns.Add(subColumn); 
            subColumn.DataField = "type_code"
            subColumn.HeaderText = "Type Code"
            subColumn.HeaderStyle.Width = 80; 
        } 
 
        //Column to use to create the RadGrid columns 
        GridBoundColumn boundColumn; 
 
        //type_code column 
        boundColumn = new GridBoundColumn(); 
        RadGrid1.MasterTableView.Columns.Add(boundColumn); 
        boundColumn.DataField = "type_code"
        boundColumn.HeaderText = "Type Code"
        boundColumn.HeaderStyle.Width = 80;//Unit.Pixel(20); 
 
        //type_value column 
        boundColumn = new GridBoundColumn(); 
        RadGrid1.MasterTableView.Columns.Add(boundColumn); 
        boundColumn.DataField = "type_value"
        boundColumn.HeaderText = "Type Value"
        boundColumn.HeaderStyle.Width = 80;// Unit.Pixel(30); 
 
        int gridWidth = 0; 
        for (int i = 0; i < RadGrid1.MasterTableView.Columns.Count; i++) 
        { 
            gridWidth += (int)RadGrid1.MasterTableView.Columns[i].HeaderStyle.Width.Value; 
        } 
        RadGrid1.Width = gridWidth + 30; 
    } 
 
 
    protected void RadGrid1_ItemCommand(object source, GridCommandEventArgs e) 
    { 
        int index = e.Item.ItemIndex; 
        subTypeCodes[index] = controller.GetTypeCode(typeCodeDataview[index]["type_value"].ToString()); 
        subTypeCodeViews[index] = subTypeCodes[index].typecode.DefaultView; 
        subTypeCodeTableViews[index].Rebind(); 
 
    } 

Basically what I'm trying to do here is create a dataset for every master row, and then populate it when the row is expanded. When I click the 'expand' button, the grid seems to disappear.
Josh
Top achievements
Rank 1
 answered on 23 Dec 2009
1 answer
158 views
I have one single page, in that all the application in terms of user control will get loaded dynamically. [By calling the LoadControl method]
On one controls I have some rad tab and their page view which also get loaded dynamically to the user control.
After clicking on one tab the images section comes up, where one can see the listing [ in  RadListView]
and can upload the images as well.
This is what I have done :
<telerik:RadUpload Localization-Select="Browse" ID="RadUpload" runat="server" ControlObjectsVisibility="AddButton"
                        MaxFileInputsCount="5" />
I am saving the images to database, but before that I had to disable the ajax, to post the file. For that I had to use this Line of code : StringBuilder js = new StringBuilder();
            js = js.Append("function conditionalPostback(sender, args){");
            js.Append("if (args.get_eventTarget() == '" + buttonSubmit.UniqueID + "') {alert('hi');");
            js.Append("args.set_enableAjax(false);}}");
            ScriptManager.RegisterClientScriptBlock(Page, typeof(Page), "UploadScript", js.ToString(), true);
       
I have tried the same js in the aspx page with the RadCodeBlock but its not working. Anyways the main problem is after uploading images first time the file input text area and the browse button got disappears, but the add and upload button remains there.
I have tried it very hard but of no luck...
Please help

Also i thought of another way to reload the whole control again after the post back that way the upload control should treat like it has come first time, but at that time after the postback, if I want to upload more images the RadUpload.UploadedFiles returns the count 0 [Seems like my js has not effected this time]

Please help

One more thing, I have missed above is this string "RadUrid=b086b64a-9a52-4bc3-8a63-5e7565d731ea " gets appended to my url, after the upload image action very first time. Im not sure what is this. And I want to get rid of this as well.[One minor item]. Please help, its urgent. [Client wants to look at this at the earliest ]

Thanks
Schlurk
Top achievements
Rank 2
 answered on 23 Dec 2009
5 answers
137 views
Greetings,

I'm currently in a bit of a pickle on a project.

I have a grid with the following columns:
DocID (bound column that is a string and display is false),
Type (a templated column that has an image in it),
DisplayName (bound column that is a string),
Owner (bound column that is an int that has display of false),
OwnerName (bound column that is a string),
ModifiedBy (bound column that is an int and has a display of false),
ModifiedByName (templated column with a label within it),
ModifiedDate (bound column with a datetime in it)

I sort on all columns, with exclusion of the ones with display hidden and Type.  The issue I'm having is with ModifiedByDate.  This column is populated with data during OnItemDataBound.  It is loaded based on the ModifiedBy field's value.  To populate it, I go to the database during OnItemDataBound and fill in the label that is within the column.

What I'm curious on is is there a way to sort this column?  Our Data Transfer Object (DTO) doesn't have a place in it for it, plus it's been deemed that it won't ever have one either.  So, my question is, how would I sort this field?  Thank you for any answers.

~Chad Johnson
Pavlina
Telerik team
 answered on 23 Dec 2009
2 answers
117 views
I apologize if I am overlooking something simple or just misunderstanding how this works but is there an easy way to retrieve a radgrid's filtered collection of data once the filtering has finished?  I would assume there would be a property of some sort I could grab and manipulate that had all of these items but I haven't found anything yet.

Could someone point me in the right direction on how I could get just the items filtered on a grid, once the filtering is finished on a server side post back.

Any help would be appreciated.

Thank you, 
Chris McMahan
Chris McMahan
Top achievements
Rank 1
 answered on 23 Dec 2009
2 answers
74 views
So I've seen some of the examples on the site, specifically http://www.telerik.com/help/aspnet/spell/spell_launching_upon_client-side_events.html and I can invoke the spell checker just fine on say a button click or some other UI event such as onblur of a textbox.  What I want to do is to spell check immediately when the page loads (without user interaction... steps described elsewhere on the site albeit for a previous version of the spell component: http://www.telerik.com/help/aspnet/spell/spell_spellchecking_in_htm,_html,_and_asp_files.html)

For some reason I can't get the GetRadSpell() function to return an instance of the Spell Editor like what happens when I click it from a button.  Is it a timing issue?  Can I not do this on the window.load event of the browser?  Is there a way to get my desired result?  My code is below.

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SpellChecker.aspx.cs" Inherits="EditorExample.SpellChecker" %>  
<%@ 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>  
    <title>Spell Checker</title>  
</head>  
<body>  
    <form id="form1" runat="server">  
        <asp:ScriptManager ID="ScriptManager1" runat="server">  
        </asp:ScriptManager>  
        <input type="text" id="test" value="misstake"/>  
        <telerik:RadSpell ID="RadSpell1" runat="server" ControlToCheck="test" IsClientID="True"  
            SupportedLanguages="en-US,English" />  
        <span onclick="doSpellCheck()">Click me to spell check</span>  
    </form>  
    <script type="text/javascript"
        function doSpellCheck() { 
            GetRadSpell('<%= RadSpell1.ClientID %>').startSpellCheck(); 
        } 
        window.onload = doSpellCheck 
    </script>  
</body>  
</html>  



Thanks!
Steven
Steven D'Anna
Top achievements
Rank 1
 answered on 23 Dec 2009
1 answer
59 views
Hello,

these days I've experienced a problem with the radTreeView-Control.

The scenario:
I've checked a node with the mouse (clicking into the checkbox).
Then I've used the down-arrow-key to go to another node and checked that node with the space key.

What hapend?
The first node - I've checked with the mouse is changing it's checked-state, every time I'm pressing the space key.

You can try, because that's behavier is in your examples two.
1. Select the node you want to check with the mouse
2. Check the node (clicking with the mouse)
3. Use the arrow-down-key
4. Check another node(s) - pressing the sapce key

Best regards.

Christian
T. Tsonev
Telerik team
 answered on 23 Dec 2009
4 answers
186 views
Does the Editor have a load or an open function that I can call to open a file in the editor text area???
I would like to know how to do it from the cobe behind but javascript will help also.
Please help!
pmoney pmoney
Top achievements
Rank 1
 answered on 23 Dec 2009
1 answer
131 views

I had AutoGenerateColumns set to True, pointed my dataset to RadGrid1.DataSource, and everything worked fine. Now I set AutoGeneateColumns to False and manually add the columns. Here's my simplified code for test purposes...

    Protected Sub CreateColumns(ByVal ds As DataSet)  
        RadGrid1.Columns.Clear()  
        RadGrid1.AutoGenerateColumns = False 
        Dim dt As DataTable = ds.Tables(0)  
        For i As Integer = 0 To dt.Columns.Count - 1  
            AddColumn(dt.Columns(i).ColumnName)  
        Next 
    End Sub 
 
    Protected Sub AddColumn(ByVal strColumnName As String)  
        Dim col As New GridBoundColumn  
        col.DataField = strColumnName  
        col.HeaderText = strColumnName  
        RadGrid1.Columns.Add(col)  
    End Sub 

After doing this, if I click on the Header to sort the column, the grid does not sort, and all the HeaderText along the top disappears. Filtering also throws this error: "is neither a DataColumn nor a DataRelation for table DefaultView". Am I missing some setting? If it helps, here's my RadGrid...

        <telerik:RadGrid ID="RadGrid1" runat="server" AllowFilteringByColumn="True" AllowPaging="True" 
            AllowSorting="True" GridLines="None" AutoGenerateColumns="False">  
            <ClientSettings> 
                <Selecting AllowRowSelect="True" /> 
            </ClientSettings> 
        </telerik:RadGrid> 

Schlurk
Top achievements
Rank 2
 answered on 23 Dec 2009
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?