Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
137 views
We've created a custom implementation of the FileBrowserContentProvider and in previous versions of the Telerik component library we were able to update/delete files without issue.  Now, however, whenever we try to update/delete we are getting the following error:

"The selected file could not be deleted because the application did not have enough permissions. Please, contact the administrator."

We've never been setting the delete/update paths as we are using DB stored images.  Could this have anything to do with it?

Thanks
Dobromir
Telerik team
 answered on 12 Jul 2010
1 answer
56 views
Hi,
As you mentioned in the below URL I tried the performance with sample applicaiton using two versions of dlls - 2009.2.826.35, 2009.3.1103.35   (http://blogs.telerik.com/tsvetomirtsonev/posts/09-10-15/radcontrols_for_asp_net_ajax_-_now_with_more_speed.aspx). But I dont see any difference b/w these two versions(Even Q3 performance is little low) . But in the Q3 2009 release notes you have mentioned (http://www.telerik.com/versionnotes.aspx?id=2127)  30% performance upgrade. Could you Please help me where I am wrong ?

Thanks
Ragupathi S
Simon
Telerik team
 answered on 12 Jul 2010
1 answer
199 views
Hello sir,

I am using Radeditor. But it's causing CSS related issue.

can u guide me what i have to do it proper.

In area of radeditor background color of my Website comes.

My web site background color is blue and same color display in area of rad editor

can u help me on his matter ?

can u guide me which setting i m missing. i have only copy dll in my bin folder.

i have attached two screen short please look it.

Thank you.
    
Bozhidar
Telerik team
 answered on 12 Jul 2010
1 answer
71 views
In Editor
1. Click Image Manager (btn) 
2. Click Upload (btn) in Image Manager Popup Layer.
3. Select File & Click Upload (btn) in Upload Popup Layer.

Question >>
After a image file was uploaded to the server successfully,
How can we preview the uploaded image automatically??
Currently as u know, we have to find the upload image and click it for previewing.
Rumen
Telerik team
 answered on 12 Jul 2010
1 answer
373 views

Hello Experts,

I found so many below enteries in my server's Event Log.
Please let us know what is this and will it affect any further.

Exception information:
    Exception type: HttpException
    Exception message: Invalid viewstate.

--------------------------------------------------
Event Type: Warning
Event Source: ASP.NET 2.0.50727.0
Event Category: Web Event
Event ID: 1309
Date:  7/9/2010
Time:  4:31:51 PM
User:  N/A
Computer: zCon-25
Description:
Event code: 3005
Event message: An unhandled exception has occurred.
Event time: 7/9/2010 4:31:51 PM
Event time (UTC): 7/9/2010 11:31:51 PM
Event ID: 4941ea0cd25f420cbbb8f4161e4e6b0e
Event sequence: 51426
Event occurrence: 270
Event detail code: 0
 
Application information:
    Application domain: /LM/W3SVC/1/Root/zCon-9-129229739136548100
    Trust level: Full
    Application Virtual Path: /zCon
    Application Path: C:\Inetpub\wwwroot\zCon.Net\
    Machine name: zCon-25
 
Process information:
    Process ID: 4148
    Process name: w3wp.exe
    Account name: zCon\SGupta
 
Exception information:
    Exception type: HttpException
    Exception message: Invalid viewstate.
 
Request information:
    Request URL: http://zCon-25/Ventures/WebResource.axd?d=qP0xs7JwfD7vLDM_
    Request path: /zCon-25/WebResource.axd
    User host address: 206.111.236.194
    User: lgant
    Is authenticated: True
    Authentication Type: Forms
    Thread account name: zCon\SGupta
 
Thread information:
    Thread ID: 11
    Thread account name: zCon-25\SGupta
    Is impersonating: True
    Stack trace:    at System.Web.UI.Page.DecryptStringWithIV(String s, IVType ivType)
   at System.Web.Handlers.AssemblyResourceLoader.System.Web.IHttpHandler.ProcessRequest(HttpContext context)
   at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
 
 
Custom event details:

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

Simon
Telerik team
 answered on 12 Jul 2010
1 answer
65 views
When I click on a menu item and drag outside the menu area while holding down the mouse, it's giving me some weird styling, which I'm assuming is in the CSS, but I can't figure out where or why that is happening. Has anybody ran into this issue before? Is this a known issue?
Simon
Telerik team
 answered on 12 Jul 2010
1 answer
144 views
Hello everybody.
I have followed the self hierarchy example you published under the ASP.NET AJAX controls page.
As long as I use it in a ASPX page everyhting works fine, but I unfortunately need to use it in an user control.
Since the function " HideExpandColumnRecursive" is called by trapping the Page_PrerenderCompletedEvent and this event does not exists in user controls, how can I hide the rows displaying "No child records to display"?
I mean, is there any event to trap in the user control or any other way to do that?

The following is the ASCX code:
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ForumSummary.ascx.cs" Inherits="RadControlsWebApp.ForumSummaryControl" %>
    <body>
        <telerik:RadStyleSheetManager ID="RadStyleSheetManager1" runat="server" />
        <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
            <Scripts>
                <%--Needed for JavaScript IntelliSense in VS2010--%>
                <%--For VS2008 replace RadScriptManager with ScriptManager--%>
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" />
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" />
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js" />
            </Scripts>
        </telerik:RadScriptManager>
        <script type="text/javascript">
        </script>
        <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
            <AjaxSettings>
                <telerik:AjaxSetting AjaxControlID="RadGrid1">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="RadGrid1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
            </AjaxSettings>
        </telerik:RadAjaxManager>
        <telerik:RadSkinManager ID="RadSkinManager1" runat="server" Skin="WebBlue">
        </telerik:RadSkinManager>
        <div>
            <asp:Label ID="Label1" runat="server" 
                        Text="Forum summary" 
                        ForeColor="White" 
                        BackColor="#9900FF"
                        BorderColor="#000099" 
                        BorderStyle="Solid" 
                        Font-Names="Arial" 
                        Font-Size="11pt" />
        </div>
        <div>
            <telerik:RadGrid ID="radGridParent" 
                                runat="server" 
                                GridLines="None"
                                Height="500px" ShowHeader="False"
                                Width="1000px"
                                Skin="Windows7"
                                AutoGenerateColumns="False"
                                OnColumnCreated="radGridParent_ColumnCreated"
                                OnItemCreated="radGridParent_ItemCreated"
                                OnItemDataBound="radGridParent_ItemDataBound">
                <ClientSettings>
                    <Selecting AllowRowSelect="True" />
                    <Scrolling AllowScroll="True" UseStaticHeaders="True" />               
                    </ClientSettings>
                <MasterTableView DataKeyNames="UniqueID, ParentID" 
                                    ShowHeader="True" 
                                    ShowFooter="true"
                                    AllowPaging="False" 
                                    PageSize="10"
                                    EditMode="InPlace"
                                    HierarchyDefaultExpanded="true" 
                                    ExpandCollapseColumn-Visible="false" 
                                    ShowHeadersWhenNoRecords="false"
                                    HierarchyLoadMode="Client" 
                                    CommandItemDisplay="None">
                    <SelfHierarchySettings ParentKeyName="ParentID" KeyName="UniqueID" />
                    <Columns>
                        <telerik:GridTemplateColumn UniqueName="columnUniqueID" Visible="False">
                            <ItemTemplate>
                                <asp:Label ID="lblUniqueID" runat="server" Text='<%# Eval("CategoryRef.UniqueID") %>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="columnParentID" Visible="false">
                            <ItemTemplate>
                                <asp:Label ID="lblParentID" runat="server" Text='<%# Eval("CategoryRef.ParentID") %>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="columnName">
                            <HeaderStyle HorizontalAlign="Center" Width="370px"/>
                            <HeaderTemplate>
                                <asp:Label ID="lblNameHeader" runat="server" Text="Categoria"/>                                   
                            </HeaderTemplate>
                            <ItemTemplate>
                                <asp:LinkButton ID="hLinkName" runat="server" OnClick="hLinkName_Click" Text='<%# Eval("CategoryRef.Name") %>'/>
                            </ItemTemplate>
                            <EditItemTemplate>
                                <asp:TextBox ID="textBoxName" runat="server" Text='<%# Eval("CategoryRef.Name") %>'/>
                                <asp:DropDownList ID="dropDownListParentsEdit" runat="server" DataValueField="UniqueID" DataTextField="Name" />
                            </EditItemTemplate>
                            <FooterTemplate >
                                <asp:TextBox ID="textBoxInsertName" runat="server"/>
                                <asp:DropDownList ID="dropDownListParents" runat="server" DataValueField="UniqueID" DataTextField="Name" />
                            </FooterTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="columnDiscussionsNumber">
                            <HeaderStyle HorizontalAlign="Center" Width="100px"/>
                            <HeaderTemplate>
                                <asp:Label ID="lblDiscussionsNumberHeader" runat="server" Text="Discussioni"/>                                   
                            </HeaderTemplate>
                            <ItemTemplate>
                                <asp:Label ID="lblDiscussionsNumber" runat="server" Text='<%# Eval("DiscussionsNumber") %>' />
                            </ItemTemplate>
                            <FooterTemplate >
                                <asp:Button ID="buttonInsert" runat="server" Text="Crea" OnClick="buttonInsert_Click"/>
                            </FooterTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="columnPostsNumber">
                            <HeaderStyle HorizontalAlign="Center" Width="100px"/>
                            <HeaderTemplate>
                                <asp:Label ID="lblPostsNumberHeader" runat="server" Text="Messaggi"/>                                   
                            </HeaderTemplate>
                            <ItemTemplate>
                                <asp:Label ID="lblPostsNumber" runat="server" Text='<%# Eval("PostsNumber") %>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="columnLastPostUrl">
                            <HeaderStyle HorizontalAlign="Center" Width="300px"/>
                            <HeaderTemplate>
                                <asp:Label ID="lblLastPostUrlHeader" runat="server" Text="Ultimo messaggio"/>                                   
                            </HeaderTemplate>
                            <ItemTemplate>
                                <asp:HyperLink ID="hLinkLastPostUrl" runat="server" NavigateUrl='<%# Eval("LastPostUrl") %>' Text='<%# Eval("LastPostUrl") %>'/>
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridEditCommandColumn>
                        </telerik:GridEditCommandColumn>
                    </Columns>
                </MasterTableView>
            </telerik:RadGrid>
        </div>
    </body>
</html>

And this the code behind:
protected void Page_Load(object sender, EventArgs e)
{
    if (Assembly.GetAssembly(typeof(ScriptManager)).FullName.IndexOf("3.5") != -1 || Assembly.GetAssembly(typeof(ScriptManager)).FullName.IndexOf("4.0") != 1)
    {
        radGridParent.MasterTableView.FilterExpression = @"!it.ParentID.HasValue";
    }
    else
    {
        radGridParent.MasterTableView.FilterExpression = "ParentID IS NULL";
    }
    LoadData();
    radGridParent.DataSource = forumSummaries;
}
protected void radGridParent_ItemCreated(object sender, GridItemEventArgs e)
{
    CreateExpandCollapseButton(e.Item, "columnName");
    if (e.Item is GridHeaderItem && e.Item.OwnerTableView != radGridParent.MasterTableView)
    {
        e.Item.Style["display"] = "none";
    }
    if (e.Item is GridFooterItem)
    {
        DropDownList ddlList = e.Item.FindControl("dropDownListParents") as DropDownList;
        if (ddlList != null)
        {
            if (ddlList.DataSource == null)
            {
                ddlList.DataSource = GetCategoriesForDropDownList();
            }
        }
    }
    if (e.Item is GridEditableItem && e.Item.IsInEditMode)
    {
        ForumSummary summary = e.Item.DataItem as ForumSummary;
        GridEditableItem item = e.Item as GridEditableItem;
        DropDownList list = item.FindControl("dropDownListParentsEdit") as DropDownList;
        if (list != null)
        {
            list.DataSource = GetCategoriesForDropDownList();
            if (summary != null)
            {
                if (summary.CategoryRef.ParentID != null)
                {
                    list.SelectedValue = summary.CategoryRef.ParentID.ToString();
                }
            }
        }
    }
    if (e.Item is GridNestedViewItem)
    {
        e.Item.Cells[0].Visible = false;
    }
}
public void HideExpandColumnRecursive(GridTableView tableView)
{
    GridItem[] nestedViewItems = tableView.GetItems(GridItemType.NestedView);
    foreach (GridNestedViewItem nestedViewItem in nestedViewItems)
    {
        foreach (GridTableView nestedView in nestedViewItem.NestedTableViews)
        {
            nestedView.Style["border"] = "0";
            Button MyExpandCollapseButton = (Button)nestedView.ParentItem.FindControl("MyExpandCollapseButton");
            if (nestedView.Items.Count == 0)
            {
                if (MyExpandCollapseButton != null)
                {
                    MyExpandCollapseButton.Style["visibility"] = "hidden";
                }
                nestedViewItem.Visible = false;
            }
            else
            {
                if (MyExpandCollapseButton != null)
                {
                    MyExpandCollapseButton.Style.Remove("visibility");
                }
            }
            if (nestedView.HasDetailTables)
            {
                HideExpandColumnRecursive(nestedView);
            }
        }
    }
}
public void CreateExpandCollapseButton(GridItem item, string columnUniqueName)
{
    if (item is GridDataItem)
    {
        int level = item.ItemIndexHierarchical.Split(':').Length;
        if (level > 1)
        {
            foreach (WebControl ctr in item.Controls)
            {
                for (int i = 0; i < ctr.Controls.Count; i++)
                {
                    if (ctr.Controls[i] is WebControl && !(ctr.Controls[i] is Button))
                    {
                        (ctr.Controls[i] as WebControl).Style["margin-left"] = level * 10 + "px";
                    }
                }
            }
        }
    }
}
As you can see by reading the code behind it misses a place where to call the HideExpandColumnRecursive that hides the the sub row of empty childs.
Is there any way to hide that??
Thanks a lot in advance.
Nick
Martin
Telerik team
 answered on 12 Jul 2010
1 answer
123 views
Hello Guys,

I have a issue with RadTreeView,
I need to prerender this control for use caching, but i received the folowing message error:
Page cannot be null. Please ensure that this operation is being performed in the context of an ASP.NET request.
at Telerik.Web.UI.ScriptRegistrar.GetScriptManager(Control control)
at Telerik.Web.UI.RadDataBoundControl.RegisterScriptDescriptors()
at Telerik.Web.UI.RadDataBoundControl.Render(HtmlTextWriter writer)

The scriptmanager is in the Masterpage.

code:

RadTreeView orgVivo =

new RadTreeView();

 

 

orgVivo.NodeExpand +=

new RadTreeViewEventHandler(orgVivo_NodeExpand);

 

 

 

 

 

//Pupulate nodes method
PupulateNodes(
);
StringBuilder
sb = new StringBuilder();

 

 

StringWriter sw = new StringWriter(sb);

 

 

using (HtmlTextWriter writer = new HtmlTextWriter(sw))

{

orgVivo.RenderControl(writer);//error >>>

}

 

 

CacheEntry cacheEntry = new CacheEntry();

cacheEntry.Date =

DateTime.Now;

 

 

cacheEntry.Html = sb.ToString();

 

 

 

this.PartCacheWrite(Storage.Shared, CACHE_KEY, cacheEntry, new TimeSpan(0, 30, 0));

 

this.Controls.Add(orgVivo);


Can you help me in this issue ?

Thanks,

Evandro Martins

 

 

 

Dimitar Milushev
Telerik team
 answered on 12 Jul 2010
2 answers
116 views
Hello,

    I am currently using the AJAX controls, is there an tutorial available on dynamically adding additional controls? What I am trying to accomplish is a  "add more" button similar to the functionality in the RadUpload control and I am attempting to use this with the RadComboBox control.

Thanks
Adonis
Top achievements
Rank 1
 answered on 12 Jul 2010
3 answers
138 views
I am using radscriptmanager with 2010 q1 telerik ajax release
     <telerik:RadScriptManager runat="server" EnableScriptCombine="false">
       <AuthenticationService Path="~/Services/SpendusAuthService.asmx" />
       <Scripts>
          <asp:ScriptReference Path="~/js/logon.js"/>
       </Scripts>
    </telerik:RadScriptManager>

In the logon.js file I need to disable ajaxtoolkit validator, and used to like this
    if (AjaxControlToolkit.ValidatorCalloutBehavior._currentCallout != null) {
        AjaxControlToolkit.ValidatorCalloutBehavior._currentCallout.hide();
    }

But I am getting AjaxControlToolkit not defined. This is the only thing not working from my .net 3.5 conversion. Any help greatly appreciated



Dimitar Milushev
Telerik team
 answered on 12 Jul 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?