Telerik Forums
UI for ASP.NET AJAX Forum
6 answers
439 views
When I click next page in radgrid it shows the following error.


Cannot unregister UpdatePanel with ID 'ctl00$ContentPlaceHolder1$RadProduct$ctl00$ctl05$ctl01$grdStockPanel' since it was not registered with the ScriptManager. This might occur if the UpdatePanel was removed from the control tree and later added again, which is not supported.
Parameter name: updatePanel
Sebastian
Telerik team
 answered on 07 Oct 2010
1 answer
286 views
Hi.  I have a radgrid with a command item template.  I have Add New Record open a radwindow.  I have an imagebutton for export to excel, and I set it up like the demo suggests (http://demos.telerik.com/aspnet-ajax/grid/examples/generalfeatures/pdfexport/defaultcs.aspx), but instead of exporting, it hides the command items.  I am posting my code below.  Could you please let me know what I am doing wrong? 
<telerik:RadScriptManager ID="RadScriptManager1" runat="server">
</telerik:RadScriptManager>
            <script type="text/javascript">
                function onRequestStart(sender, args) {
                    if (args.get_eventTarget().indexOf("excelExport") > 0) {
 
                        args.set_enableAjax(false);
                    }
                }
                function ShowInsertForm() {
                    var combo = $find("<%= RadComboBox1.ClientID %>");
                    var comboItem = combo.get_selectedItem();
                    if (!comboItem)
                    {
                        window.radopen("AddComment.aspx", "UserListDialog");
                    }
                    else {
                        window.radopen("AddComment.aspx?something=" + comboItem.get_value("something"), "UserListDialog");
                    }
                    return false;
                }
                function refreshGrid() {
                    $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("Rebind");
                }
            </script>
<telerik:RadGrid ID="RadGrid1" runat="server" AllowFilteringByColumn="True"
                        AllowPaging="True" AllowSorting="True" GridLines="None" Skin="WebBlue"
                        OnNeedDataSource="RadGrid1_NeedDataSource"
                        OnDataBound="RadGrid1_DataBound" width="873px"
                        AutoGenerateColumns="False">
                        <ExportSettings  ExportOnlyData="true" IgnorePaging="true" OpenInNewWindow="true">
                            <Excel Format="ExcelML" />
                        </ExportSettings>
                        <ClientSettings AllowColumnsReorder="True" ReorderColumnsOnClient="True">
                        </ClientSettings>
                        <MasterTableView CommandItemDisplay="Top" >
                            <CommandItemSettings >
                             </CommandItemSettings>
                            <RowIndicatorColumn>
                                <HeaderStyle Width="20px"></HeaderStyle>
                            </RowIndicatorColumn>
                            <ExpandCollapseColumn>
                                <HeaderStyle Width="20px"></HeaderStyle>
                            </ExpandCollapseColumn>
                            <Columns>
                                <telerik:GridBoundColumn DataField="something0" HeaderText="Grantee"
                                    UniqueName="column">
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn DataField="something" HeaderText="PO" UniqueName="column1">
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn DataField="something1" FilterControlWidth="30px"
                                    HeaderText="Comment Date" UniqueName="column2">
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn DataField="something2" HeaderText="Commentor"
                                    UniqueName="column3">
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn DataField="something3" HeaderText="Comment"
                                    UniqueName="column4">
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn DataField="InsertDate" FilterControlWidth="30px"
                                    HeaderText="Insert Date" UniqueName="something4">
                                </telerik:GridBoundColumn>
                            </Columns>
                            <CommandItemTemplate>
                                <a href="#" onclick="return ShowInsertForm();">Add New Record</a>
                                <asp:ImageButton ID="excelExport" runat="server" ImageUrl="~/images/ExportToExcel.gif" CommandName="ExportToExcel" />
                            </CommandItemTemplate>
                        </MasterTableView>
                    </telerik:RadGrid>

Thank you.
GP
Top achievements
Rank 1
 answered on 07 Oct 2010
2 answers
268 views
Hi, i got this radgrid, with 1 boundcolumn and some template columns (all chkbxs)...

<
telerik:RadGrid ID="rggrupos" DataSourceID="dsGrupos" runat="server"
           AutoGenerateColumns="False" GridLines="none">
            <MasterTableView Width="100%">
                <GroupByExpressions>
                    <telerik:GridGroupByExpression>
                        <SelectFields>
                            <telerik:GridGroupByField FieldAlias="Grupo" FieldName="grupo"></telerik:GridGroupByField>
                              
                        </SelectFields>
                        <GroupByFields>
                            <telerik:GridGroupByField FieldName="grupo" SortOrder="Ascending"></telerik:GridGroupByField>
                        </GroupByFields>
                    </telerik:GridGroupByExpression>
                </GroupByExpressions>
                <Columns>
                    <telerik:GridBoundColumn SortExpression="usuario" HeaderText="" HeaderButtonType="TextButton"
                        DataField="usuario">
                    </telerik:GridBoundColumn>
                    <telerik:GridTemplateColumn UniqueName="temprespseg"  HeaderText="RESPSEG"  >  
                                <ItemTemplate>  
                                    <asp:CheckBox ID="chkrespseg" runat="server" onclick="Check(this);"  />  
                                </ItemTemplate>  
                            </telerik:GridTemplateColumn
                            <telerik:GridTemplateColumn UniqueName="tempatender"  HeaderText="ATENDER"  >  
                                <ItemTemplate>  
                                    <asp:CheckBox ID="chkatender" runat="server" onclick="Check(this);"  />  
                                </ItemTemplate>  
                            </telerik:GridTemplateColumn
                            <telerik:GridTemplateColumn UniqueName="tempcomentar"  HeaderText="COMENTAR"  >  
                                <ItemTemplate>  
                                    <asp:CheckBox ID="chkcomentar" runat="server" onclick="Check(this);"  />  
                                </ItemTemplate>  
                            </telerik:GridTemplateColumn
                            <telerik:GridTemplateColumn UniqueName="tempenterar"  HeaderText="ENTERAR"  >  
                                <ItemTemplate>  
                                    <asp:CheckBox ID="chkenterar" runat="server" onclick="Check(this);"  />  
                                </ItemTemplate>  
                            </telerik:GridTemplateColumn
                            <telerik:GridTemplateColumn UniqueName="temparchivar"  HeaderText="ARCHIVAR"  >  
                                <ItemTemplate>  
                                    <asp:CheckBox ID="chkarchivar" runat="server" onclick="Check(this);"  />  
                                </ItemTemplate>  
                            </telerik:GridTemplateColumn
                             </Columns>
            </MasterTableView>
  
        </telerik:RadGrid>
What i need to to is to select (mark) some of the checkboxes on each row, and by clickin a button i want to know wich checkboxes are selected on each row, i identify each row by the first bound column (usuario)
btw, my code file is in vb

Thanks for your time.!

Carlos Nava
Carlos
Top achievements
Rank 1
 answered on 07 Oct 2010
5 answers
94 views
Hi Folks,

I'm trying to follow the example as in http://demos.telerik.com/aspnet-ajax/grid/examples/hierarchy/nestedviewtemplatedeclarativerelations/defaultcs.aspx.

I guess I don't understand the method by which the NestedView gets the Master DataKey ID value.  Clicking on the details arrow always returns the first record.

As in the example, the data is coming from the same table. There are two data sources defined, one for the Master and one for the Nested views.
<asp:LinqDataSource ID="VendorDataSource" EnableObjectTracking="true" EnableUpdate="true" runat="server"
    ContextTypeName="admin.MTSDataClassesDataContext" EntityTypeName=""
    TableName="Vendors">
</asp:LinqDataSource>
<asp:LinqDataSource ID="VendorDetailsDataSource"  EnableUpdate="true" runat="server"
    ContextTypeName="admin.MTSDataClassesDataContext" EntityTypeName=""
    Select="new (ID, Description, Address1, Address2, City, Email2, Phone, FAX, Mobile, Zip, StateID, CountryID, Country, State)"
    Where="ID==@ID"
    TableName="Vendors">
 
    <SelectParameters>
        <asp:Parameter Name="ID" Type="Int32" />
    </SelectParameters>
</asp:LinqDataSource>

The NestedViewSettings are:
<NestedViewSettings DataSourceID="VendorDetailsDataSource">
    <ParentTableRelation>
        <telerik:GridRelationFields  DetailKeyField="ID" MasterKeyField="ID" />
    </ParentTableRelation>
</NestedViewSettings>

and the MasterTable View settings:
<MasterTableView AllowAutomaticUpdates="true" DataKeyNames="ID"  DataSourceID="VendorDataSource">

Again, the issue is that clicking on the details arrow always returns the first item in the database, not the details for the record that was clicked on. 

Thanks for any help.

Rick



Pavlina
Telerik team
 answered on 07 Oct 2010
2 answers
201 views
Some of the items in my RadComboBox are long, and wrap when the dropdown opens. The issue is that in Internet Explorer, when you select one of these items with your mouse, the selected item is aligned wrong. It should display the beginning of the selection, with the end of it hidden. That is the behavior in other browsers. IE also works properly when you use the keyboard to make the selection. This issue is only when the mouse is used to select the item. It appears that using the mouse leaves the text selected, and might have something to do with why this is happening, but setting EnableTextSelection to false does not resolve the issue.

In the demo, if you look at it in IE, you can reproduce the problem. After loading the page, use the mouse to open the "Dealer" combo. It's the most obvious when you select an item that's very long, such as "Nord-Ost-Fisch Handelsgesellschaft mbH". The text that will show is "Ost-Fisch Handelsgesellschaft mbH", because it's aligned wrong. What should be showing is "Nord-Ost-Fisch Handelsgesellsch".

I do see an article for your Silverlight controls that shows how to resolve the issue, so I'm hoping you have a resolution for these controls.

Thanks,
Misty

Misty Fowler
Top achievements
Rank 1
 answered on 07 Oct 2010
3 answers
172 views
Hi,

We are using the RadGrid control in one of the pages we are developing to display the hierarcical relation between 2 entities. When the user clicks on the expand button (the tiny arrow in the left hand side of the row), the detail table expands and displays the depended entitites (this part works as expected). But when the user clicks on the collapse button, the details displayed are not getting collapsed. Could anyone please give some info on how to collapse the details when the user is clicking on the collapse button?

Thanks,
Manoj
Pavlina
Telerik team
 answered on 07 Oct 2010
2 answers
109 views
PLEASE IGNORE THIS.  IT WAS A SIMPLE HTML ISSUE.  I COULD NOT FIGURE OUT HOW TO DELETE A THREAD!


I am implementing a radGrid with a custom ItemTemplate.  I am adding a tooltip declaratively in the ItemTemplate, and binding the tooltip to a targetcontrol in the grid's ItemDataBound event.  The result is that only the FIRST row will properly display the tooltip.

(simplified version of the code):
 <telerik:RadGrid ID="grdFilter" runat="server" GridLines="None" AllowPaging="true" AllowSorting="true" ShowHeader="false"  
                           PageSize="18" OnPreRender="grdFilter_PreRender" OnNeedDataSource="grdFilter_NeedDataSource" OnItemDataBound="grdFilter_ItemDataBound" 
                            OnItemCreated="grdFilter_ItemCreated" OnItemCommand="grdFilter_ItemCommand"
<MasterTableView ItemStyle-CssClass="grdAAP" AlternatingItemStyle-CssClass="grdAAP" PagerStyle-Mode="Slider"
<ItemTemplate> 
                              <telerik:RadToolTip ID="RadToolTip1" runat="server" IsClientID="true" RelativeTo="Element" Position="Center"
                              <asp:PlaceHolder ID="phToolTip" runat="server"></asp:PlaceHolder> 
                            </telerik:RadToolTip> 
<asp:panel ID="itemcontainer" CssClass="item" runat="server"
 <asp:Label ID="lblDetails" runat="server" Text="Details..."></asp:Label> 
</asp:panel> 
</ItemTemplate> 
                <PagerStyle Position="Top" AlwaysVisible="true" /> 
     </MasterTableView> 
</telerik:RadGrid> 

On the ItemDataBound event, I populate the ToolTip with the contents of a UserControl
 protected void grdFilter_ItemDataBound(object source, Telerik.Web.UI.GridItemEventArgs e) 
        { 
            if (e.Item is GridDataItem) 
            { 
 DataRowView dvthis = (DataRowView)e.Item.DataItem; 
 PlaceHolder phTooltip = (PlaceHolder) e.Item.FindControl("phToolTip"); 
                RadToolTip rTooltip = (RadToolTip)e.Item.FindControl("RadToolTip1"); 
                Label lblTT = (Label) e.Item.FindControl("lblDetails"); 
                rTooltip.TargetControlID = lblTT.ClientID; 
                rTooltip.IsClientID = true
 String sku = dvthis["SKU"].ToString(); 
                Control ctrl = LoadControl("AAPTooltip.ascx"); 
                AAPTooltip details = (AAPTooltip)ctrl; 
                details.productID = sku; 
 
                phTooltip.Controls.Add(details); 
       } 

The result is that only the FIRST item in the grid will properly display the tooltip.  It is important to note that the end result of the grid is NOT the typical row grid, but rather three columns of "rows" next to eachother, similar to this example:
http://demos.telerik.com/aspnet-ajax/grid/examples/programming/listview/defaultcs.aspx


Thank you.




Lars Meyer
Top achievements
Rank 2
 answered on 07 Oct 2010
3 answers
254 views
The RadEditor supports a rudimentary insert special symbol popup, and I know it's possible to edit the symbols in the ToolsFile.xml.  However, I need to be able to enter most unicode characters.  I'm looking for something more like the attached popup from MS Word's insert special character dialog box (see attachment).

These are the problems I am having with the built-in insert special in RadEditor:

1) The insert symbol menu gives you a popup that is only 8 characters wide
2) There is no provision to scroll through many many symbols or to organize them into logical groups
3) I have to manually edit the ToolsFile.xml to create the symbols, there are thousands of them!
4) and (perhaps the most important), the symbol that gets inserted is the actual numeric code for the characters and this can break the html.  What is needed is the ability to insert the symbol as html markup as in like:  
&#nnnn;

So, what I'm wondering, is there a widget or plug-in out there that handles special characters better than the built-in omega insert symbol menu?  Would it be difficult to build something better?



Rumen
Telerik team
 answered on 07 Oct 2010
1 answer
60 views
Hello guys,
I've used a dozen RadGrids on various pages, and for some reason I've got one RadGrid used in one user control, that will not respond to any activity on the pager.

The spinner, in the left side of the pager, spins when any pager controls are clicked, but the data does not update in the grid.

Can anyone please provide a few ideas I can check? 

<telerik:RadGrid ID="_newEntityCreativeGrid" runat="server" PageSize="10" AllowSorting="true" ShowHeader="true"
        ShowFooter="false" ShowStatusBar="true" AllowPaging="true" EnableViewState="true">
        <MasterTableView AutoGenerateColumns="false">
            <Columns>
                <telerik:GridBoundColumn DataField="CreativeID" DataType="System.Int32" HeaderText="Creative Id"
                    Visible="false" />
                <telerik:GridBoundColumn DataField="CreativeType" DataType="System.Int32" HeaderText="Creative Type"
                    Visible="false" />
                <telerik:GridBoundColumn DataField="BrandID" DataType="System.Int32" HeaderText="Brand Id"
                    Visible="false" />
                <telerik:GridButtonColumn DataTextField="BrandName" UniqueName="BrandName" DataType="System.String"
                    HeaderText="Brand Name" CommandName="Brand" />
                <telerik:GridBoundColumn DataField="ParentID" DataType="System.Int32" HeaderText="Parent Id"
                    Visible="false" />
                <telerik:GridButtonColumn DataTextField="ParentName" UniqueName="ParentName" DataType="System.String"
                    HeaderText="Parent Name" CommandName="Parent" />
                <telerik:GridBoundColumn DataField="AdvertiserID" DataType="System.Int32" HeaderText="Advertiser Id"
                    Visible="false" />
                <telerik:GridButtonColumn DataTextField="AdvertiserName" UniqueName="AdvertiserName"
                    DataType="System.String" HeaderText="Advertiser" CommandName="Advertiser" />
                <telerik:GridBoundColumn DataField="ProductID" DataType="System.Int32" HeaderText="Product Id"
                    Visible="false" />
                <telerik:GridButtonColumn DataTextField="ProductName" UniqueName="ProductName" DataType="System.String"
                    HeaderText="Product Name" CommandName="Product" />
                <telerik:GridBoundColumn DataField="CategoryID" DataType="System.Int32" HeaderText="Category Id"
                    Visible="false" />
                <telerik:GridBoundColumn DataField="CategoryName" DataType="System.String" HeaderText="Category Name" />
                <telerik:GridBoundColumn DataField="PropertyID" DataType="System.Int32" HeaderText="Property Id"
                    Visible="false" />
                <telerik:GridBoundColumn DataField="PropertyName" UniqueName="PropertyName" DataType="System.String"
                    HeaderText="Property Name" Visible="false" />
                <telerik:GridBoundColumn DataField="FirstAppearedDate" HeaderText="First Appeared Date"
                    Visible="false" DataType="System.DateTime" />
                <telerik:GridBoundColumn DataField="FirstAppeared" UniqueName="FirstAppeared" DataType="System.String"
                    HeaderText="First Appeared" />
            </Columns>
        </MasterTableView>
        <ClientSettings>
            <Selecting AllowRowSelect="false"></Selecting>
        </ClientSettings>
    </telerik:RadGrid>
Pavlina
Telerik team
 answered on 07 Oct 2010
1 answer
115 views
Hi,

We are using RadAjaxManager and AjaxSettings for our application.
We have one parent page with multiple user controls and each user control having "AjaxRequest" event.
Parent page only having RadAjaxManager object.
And "OnPreRender" of each user control we are setting loading panel.
e.g. RadAjaxManager.AjaxSettings.AddAjaxSetting(control, control, RadAjaxLoadingPanel1);

Problem - Now due to AjaxRequest event when user clicks on any user control's feature it shows all user controls RadAjaxLoadingPanel1(images), not for selected user control only.

Can you please help us out here.

Regards,
SL
Dimo
Telerik team
 answered on 07 Oct 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Andrey
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Andrey
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?