Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
95 views
I am using 2008.3.1125.35 Telerik.Web.UI dll. i have export button after loading the page if we click the export after export is done if we try to click on filter icon which is there on grid column. filter menu is not coming.
Please help us to solve this problem.
Pavlina
Telerik team
 answered on 11 Nov 2009
1 answer
432 views
Hello,

I have a situation where I'm registering scripts with the script manager. I'm wondering if there is a check to see if the script is already registered in the manager before adding it.

I'm using a single page design model and what is happening is scripts are being added to the page more than once.

I'm looking for a property of the script manager or ajax manager to be something like IsScriptSet or even some functionality to simple check to ensure scripts are already added and if so, don't add again, just ignore the registration with the script manager.

The big issue, to clarify, is that my page is getting bloated with duplicate scripts being registered when users interact with my single page interface to my website.  Please Help me stop the bloat!! :) Getting away from the single page design is not an option, it's in stone at the moment, so we need a check.

I appreciate any advice or feedback. Thanks very much.
Veselin Vasilev
Telerik team
 answered on 11 Nov 2009
3 answers
135 views
Hi!

When a Dock is collapsed (dock.set_collapsed(true)), I do some custom javascript where I calculate heights of docks in my dock layout. But when using animation (dock.set_collapsed(true, true)), my calculations gets incorrect since the animation is ended AFTER my calculation.
Is there any way of subscribing to an animation ended event so I can do my calculations when the animation has ended?

Regards
Obi-Wan Kenobi
Top achievements
Rank 1
 answered on 11 Nov 2009
1 answer
114 views
I've noticed in HTML view if I put in HTML w/ CSS like this:


<div style="border:2px solid #cc0000; width: 180px; font-size: 16px; text-align: center; ">

after I save it becomes something much less readable, such as:

<div style="border-top-width: 2px; border-right-width: 2px; border-bottom-width: 2px; border-left-width: 2px; border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; border-top-color: #cc0000; border-right-color: #cc0000; border-bottom-color: #cc0000; border-left-color: #cc0000; width: 180px; font-size: 16px; text-align: center; ">

Why is this happening, and how do I prevent it?
Rumen
Telerik team
 answered on 11 Nov 2009
1 answer
114 views
Hi

I have followed the instructions in this article to allow me to add a Save button to my toolbar which uses a RadAjaxManager to run some Javascript which causes a postback to the server. 

When the user presses the Save button I want to display a "Saving ..." animation while the server side script is executing.  Is there an example which shows how this can be achieved using the RadAjaxLoadingPanel and RadAjaxManager ?

Thanks

Steve
Rumen
Telerik team
 answered on 11 Nov 2009
1 answer
87 views
Hi,

I'm using the RadGrid in WebUserControl EditMode, and I've dynamically added two dropdownlists (they are inherited extensions of the ASP dropdownlists) and one CascadingDropDown from the AjaxControlToolkit.
If I do this inside my edit user control, I get a NullReference exception, the stacktrace is here:
   at AjaxControlToolkit.ExtenderControlBase.GetScriptDescriptors(Control targetControl)
   at System.Web.UI.ExtenderControl.System.Web.UI.IExtenderControl.GetScriptDescriptors(Control targetControl)
   at Telerik.Web.UI.ProxyScriptControl.GetChildScriptDescriptorsRecursive(Control parent, ArrayList scriptDescriptors)
   at Telerik.Web.UI.ProxyScriptControl.GetChildScriptDescriptorsRecursive(Control parent, ArrayList scriptDescriptors)
   at Telerik.Web.UI.ProxyScriptControl.GetChildScriptDescriptorsRecursive(Control parent, ArrayList scriptDescriptors)
   at Telerik.Web.UI.ProxyScriptControl.GetChildScriptDescriptorsRecursive(Control parent, ArrayList scriptDescriptors)
   at Telerik.Web.UI.ProxyScriptControl.GetChildScriptDescriptorsRecursive(Control parent, ArrayList scriptDescriptors)
   at Telerik.Web.UI.ProxyScriptControl.GetChildScriptDescriptorsRecursive(Control parent, ArrayList scriptDescriptors)
   at Telerik.Web.UI.ProxyScriptControl.GetChildScriptDescriptorsRecursive(Control parent, ArrayList scriptDescriptors)
   at Telerik.Web.UI.ProxyScriptControl.GetChildScriptDescriptorsRecursive(Control parent, ArrayList scriptDescriptors)
   at Telerik.Web.UI.ProxyScriptControl.GetChildScriptDescriptorsRecursive(Control parent, ArrayList scriptDescriptors)
   at Telerik.Web.UI.ProxyScriptControl.GetChildScriptDescriptorsRecursive(Control parent, ArrayList scriptDescriptors)
   at Telerik.Web.UI.ProxyScriptControl.GetScriptDescriptors()
   at System.Web.UI.ScriptControlManager.RegisterScriptDescriptors(IScriptControl scriptControl)
   at System.Web.UI.ScriptManager.RegisterScriptDescriptors(IScriptControl scriptControl)
   at Telerik.Web.UI.ProxyScriptControl.Render(HtmlTextWriter writer)
   at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter)
   at System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter)
[...]

The edit control works if I don't add the CascadingDropDown to the control tree, and everything works if I add it outside the grid.

What should I try?

Thanks,


   At.
Sebastian
Telerik team
 answered on 11 Nov 2009
1 answer
258 views

I use problems binding RadGrid to Entity Framework-objects.

I have two tables:

User:
UserID
Name
Age
GroupID

Group:
GroupID
Name

In entity framework, i get two Entitytypes. First User with properties UserID, Name, Age and Navigation property Group. Entity set name is set to Users. Second EntityType is Group with GroupID and Name as properties, and a navigation property named Users pointing to a collection of User-entities.

To fetch all users and include the group i use the following code:

private List<User> GetUsers()  
{  
 var users = from u in entities.Users  
   .include("Group")  
   select u;  
 return users.ToList();  
    

Binding the grid to the list of User-objects is no problem.

Grid.Datasource = GetUsers();  
Grid.Databind();  
 
 

I add the following columns to the grid.

<telerik:GridBoundColumn DataField="Name" UniqueName="Name" HeaderText="Name" />  
<telerik:GridBoundColumn DataField="Age" UniqueName="Age" HeaderText="Age" />  
<telerik:GridBoundColumn DataField="Group.Name" UniqueName="Group" HeaderText="Group Name" />  
 
 

All data is displayed, no problem yet.

I want the 3rd column to be a GridDropDownColumn instead. I tried to use a GridDropDownColumn, but it didn't work, all rows were blank:

<telerik:GridDropDownColumn DataField="Group.Name" UniqueName="Group" HeaderText="Group" />  
 
 

I read in another thread that GridDropDownColumn is mainly for DataTables, so i tries to use GridTemplateColumn instead, and it almost works.

 

<telerik:GridTemplateColumn DataField="Group.Name" UniqueName="Group" HeaderText="Group">  
 <ItemTemplate>  
  <asp:Label ID="Label1" runat="server" Text='<%#Bind("Group.Name") %>'></asp:Label>  
 </ItemTemplate>  
 <EditItemTemplate>  
  <telerik:RadComboBox ID="EditGroupRadComboBox"  runat="server" />  
 </EditItemTemplate>  
</telerik:GridTemplateColumn>  
 

The RadComboBox is bound to data in ItemDataBound:

if (e.Item is GridEditableItem && (e.Item as GridEditableItem).IsInEditMode)  
{  
 GridEditableItem editedItem = e.Item as GridEditableItem;  
 RadComboBox combo = (RadComboBox)editedItem.FindControl("EditGroupRadComboBox");  
 
 combo.DataSource = GetGroups(); //returns List<Group>  
 combo.DataTextField = "Name";  
 combo.DataValueField = "GroupID";  
 
 combo.DataBind();  
 combo.SelectedValue = ((User)editedItem.DataItem).Group.GroupID.ToString();   
}  
 
 

It works as expected, the groups are displayed in the RadComboBox, and the correct option is selected.

Now to the problem, how do I perform the update? I tried he following in ItemCommand-event, but the user-object contains the old values

if (e.CommandName == "Update")  
{  
 User user = e.Item.DataItem as User;  
}  
 

I looked at the following thread, with a similar problem: http://www.telerik.com/community/forums/aspnet-ajax/grid/radcombobox-in-gridtemplatecolumn.aspx
I tried to set SelectedValue='<%#Bind("Group.GroupID") %>', but i get an exception, saying Group.GroupID is invalid.

 
Kind Regards, Johan

Sebastian
Telerik team
 answered on 11 Nov 2009
2 answers
111 views
Hi,

In a hierarchical datagrid with two levels I am trying to keep the edited item expanded through

Public Sub Command_Row(ByVal Sender As Object, ByVal e As Telerik.Web.UI.GridCommandEventArgs) 
 
If (TypeOf (e.Item) Is GridDataItem) Then 
'do the stuff here 
 
dtgProducts.ReBind() 
e.Item.OwnerTableView.ParentItem.Expanded = True 
End if 
 
End Sub 
Does anybody have a clue why this isn't working?

Marc






Fit2Page
Top achievements
Rank 2
Bronze
Iron
Iron
 answered on 11 Nov 2009
1 answer
44 views
Everytime that we click an image button inside an RadAjaxPanel in Firefox we get the same error:

"Input string was not in a correct format."

And the event onClick is not executed

In IE works fine.

We are using Q3 2009.

Thanks,

Ricard.
Martin
Telerik team
 answered on 11 Nov 2009
1 answer
67 views
Please let us know how to avoid autocomplete in Rad Date Input. Pls find the screen shot
Dimo
Telerik team
 answered on 11 Nov 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?