Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
37 views
I see that a lot of my controls in editor have a header and footer sub elements. For example, I have a RadTextBox that has sub elements "Header" and "Footer." I haven't figured out what these two things are. What are they?
Maria Ilieva
Telerik team
 answered on 11 Oct 2012
2 answers
72 views
Hi all:
    My front code is below:


<telerik:RadGrid ID="rgLeaveHistory" runat="server" AutoGenerateColumns="False" CellSpacing="0" GridLines="None" AllowFilteringByColumn="True">
                <MasterTableView DataKeyNames="ActionLinkArg" AllowFilteringByColumn="True">
                    <Columns>
                        <telerik:GridTemplateColumn UniqueName="RgLeaveHistory_Cancel">
                            <HeaderTemplate>
                                <asp:Label ID="lblHeaderRgLeaveHistory_Cancel" runat="server" Text='<%#UIUtil.GetLabel("Cancel",UIUtil.GetLangCode(request))%>'></asp:Label></HeaderTemplate><ItemTemplate>
                                <asp:ImageButton ID="btnRgLeaveHistory_Cancel" runat="server" ImageUrl='<%# Tier_Common.GetStr_ImagePath("Delete")  %>' CommandName="Cancel"/>
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="RgLeaveHistory_RefId">
                            <HeaderTemplate>
                                <asp:Label ID="lblHeaderRgLeaveHistory_RefId" runat="server" Text='<%#UIUtil.GetLabel("RefId",UIUtil.GetLangCode(request))%>'></asp:Label></HeaderTemplate><ItemTemplate>
                                <asp:Label ID="lblItemRgLeaveHistory_RefId" runat="server" Text='<%#Eval("RefId")%>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="RgLeaveHistory_Status">
                            <HeaderTemplate>
                                <asp:Label ID="lblHeaderRgLeaveHistory_Status" runat="server" Text='<%#UIUtil.GetLabel("Status",UIUtil.GetLangCode(request))%>'></asp:Label></HeaderTemplate><ItemTemplate>
                                <asp:Label ID="lblItemRgLeaveHistory_Status" runat="server" Text='<%#Eval("Status")%>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="RgLeaveHistory_LvType">
                            <HeaderTemplate>
                                <asp:Label ID="lblHeaderRgLeaveHistory_LeaveType" runat="server" Text='<%#UIUtil.GetLabel("LeaveType",UIUtil.GetLangCode(request))%>'></asp:Label></HeaderTemplate><ItemTemplate>
                                <asp:Label ID="lblItemRgLeaveHistory_LeaveType" runat="server" Text='<%#Eval("LeaveType")%>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="RgLeaveHistory_FromDate">
                            <HeaderTemplate>
                                <asp:Label ID="lblHeaderRgLeaveHistory_FromDate" runat="server" Text='<%#UIUtil.GetLabel("FromDate",UIUtil.GetLangCode(request))%>'></asp:Label></HeaderTemplate><ItemTemplate>
                                <asp:Label ID="lblItemRgLeaveHistory_FromDate" runat="server" Text='<%#Eval("FromDate")%>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="RgLeaveHistory_FromTime">
                            <HeaderTemplate>
                                <asp:Label ID="lblHeaderRgLeaveHistory_FromTime" runat="server" Text='<%#UIUtil.GetLabel("FromTime",UIUtil.GetLangCode(request))%>'></asp:Label></HeaderTemplate><ItemTemplate>
                                <asp:Label ID="lblItemRgLeaveHistory_FromTime" runat="server" Text='<%#Eval("FromTime")%>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="RgLeaveHistory_ToDate">
                            <HeaderTemplate>
                                <asp:Label ID="lblHeaderRgLeaveHistory_ToDate" runat="server" Text='<%#UIUtil.GetLabel("ToDate",UIUtil.GetLangCode(request))%>'></asp:Label></HeaderTemplate><ItemTemplate>
                                <asp:Label ID="lblItemRgLeaveHistory_ToDate" runat="server" Text='<%#Eval("ToDate")%>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="RgLeaveHistory_ToTime">
                            <HeaderTemplate>
                                <asp:Label ID="lblHeaderRgLeaveHistory_ToTime" runat="server" Text='<%#UIUtil.GetLabel("ToTime",UIUtil.GetLangCode(request))%>'></asp:Label></HeaderTemplate><ItemTemplate>
                                <asp:Label ID="lblItemRgLeaveHistory_ToTime" runat="server" Text='<%#Eval("ToTime")%>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="RgLeaveHistory_TotalDays">
                            <HeaderTemplate>
                                <asp:Label ID="lblHeaderRgLeaveHistory_TotalDays" runat="server" Text='<%#UIUtil.GetLabel("TotalDays",UIUtil.GetLangCode(request))%>'></asp:Label></HeaderTemplate><ItemTemplate>
                                <asp:Label ID="lblItemRgLeaveHistory_TotalDays" runat="server" Text='<%#Eval("TotalDays")%>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                        <telerik:GridTemplateColumn UniqueName="RgLeaveHistory_TotalDays">
                            <HeaderTemplate>
                                <asp:Label ID="lblHeaderRgLeaveHistory_Remarks" runat="server" Text='<%#UIUtil.GetLabel("Remarks",UIUtil.GetLangCode(request))%>'></asp:Label></HeaderTemplate><ItemTemplate>
                                <asp:Label ID="lblItemRgLeaveHistory_Remarks" runat="server" Text='<%#Eval("Remarks")%>' />
                            </ItemTemplate>
                        </telerik:GridTemplateColumn>
                     </Columns>
                 </MasterTableView>
                 <FilterMenu EnableImageSprites="False"></FilterMenu>
            </telerik:RadGrid>

It shows error: "Multiple controls with the same ID 'FilterTextBox_' were found. FindControl requires that controls have unique IDs."
But when I set the property AllowFilteringByColumn to be false , It shows no problem.

Could you help me? Thanks
Singl Pang
Top achievements
Rank 1
 answered on 11 Oct 2012
10 answers
168 views
I have a RadEditor nested inside a FormView so that I can bind database data inside.  This is working nicely.  In trying to save the content of the RadEditor back to the database, however, my CodeFile isn't recognizing my RadEditor.  Here's my .aspx:
<asp:FormView ID="FormView1" runat="server" DataSourceID="editcontentDS"
      DefaultMode="Edit">
<EditItemTemplate>
  <telerik:RadEditor ID="RadEditor1" runat="server" EnableResize="False" Skin="Sunset" Width="950px" Content='<%# Bind("content_detail") %>'>
      <Tools>
          <telerik:EditorToolGroup>
              <telerik:EditorTool Name="Bold" />
              <telerik:EditorTool Name="Italic" />
              <telerik:EditorTool Name="FindAndReplace" />
              <telerik:EditorTool Name="AjaxSpellCheck" />
              <telerik:EditorTool Name="ForeColor" />
              <telerik:EditorTool Name="Undo" />
              <telerik:EditorTool Name="Redo" />
          </telerik:EditorToolGroup>
      </Tools>
  </telerik:RadEditor>
  <br />
  <asp:Button ID="UpdateButton" runat="server" CausesValidation="false" CommandName="Update" Text="Update" />
  <input id="UpdateCancelButton" type="button" value="Cancel" onclick="history.go(-1);return false;" />
</EditItemTemplate>
</asp:FormView>
Then there's my SqlDataSourse:
<asp:SqlDataSource ID="editcontentDS" runat="server"
    ConnectionString="<%$ ConnectionStrings:myconnection %>"
    SelectCommand="SELECT content_detail FROM content_items WHERE pages_id = 1"
    UpdateCommand="UPDATE content_items SET content_detail=@pageContent WHERE pages_id = 1">
    <UpdateParameters>
        <asp:Parameter Name="pageContent" Type="String" />
    </UpdateParameters>
</asp:SqlDataSource>
And lastly my lonely CodeFile:
Protected Sub editcontentDS_Updating(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.SqlDataSourceCommandEventArgs) Handles editcontentDS.Updating
    Dim updatedContent As String = RadEditor1.Content
 
End Sub
RadEditor1 has the following error: 'RadEditor1' is not declared. It may be inaccessible due to its protection level.

Any ideas?
Abhishek
Top achievements
Rank 1
 answered on 11 Oct 2012
1 answer
188 views
Hi,

I my web application, i implemented radconfirm to validate the fileds.When the alert is showing the backround contents are invisible.

Please find the attachment for your referrence.

Thanks,
Venkatesh S

Maria Ilieva
Telerik team
 answered on 11 Oct 2012
1 answer
82 views
I have attached related files for a clearer explanation...

I created a custom skin using your online tool and that went well.  I downloaded and unzipped the file and installed the contents in my .net 4.0 web site project (VS2012). I named the custom skin "Custom" for the sake of brevity and easy testing.  You can see the resulting structure in ProjectLayout.png.

I turned off embedded skins in the menu control and included the name of the skin as well.  Please refer to menucontrol.png for that definition.  One note...this is in a user control and not being placed directly on a web page.

When the page/user control is displayed, there are no styles being applied to the menu (please refer to DisplayedMenu.png).  If I change the "embedded skins" property to true and the name of the skin to one of the included skins, it displays just fine according to the selected embedded skin.

In addition, no skin/css files are being called for during the page display.  You can see that in the included Fiddler screen capture.

I'm pretty certain I'm missing something really stupid, but I have followed the instructions in the video for the Visual Style Builder (which was an otherwise good video).

Can anyone tell me what I am missing?

Thanks in advance for assistance!

Lynn
Kate
Telerik team
 answered on 11 Oct 2012
1 answer
124 views
Hello,

I've search high and low for help on what I am trying to do, which seems pretty simple.

Basically, I want to create a number of RadDocks depending upon how many rows I have in a table which holds photos and data associated with them.  I am trying to add a few buttons to the RadDock that will do stuff, like delete a photo.

Here is what I have so far:

DataTable dtPhotos = GetAllByGalleryID(ID);
 
        if (dtPhotos.Rows.Count > 0)
        {
            foreach (DataRow dr in dtPhotos.Rows)
            {
                RadDock dock = new RadDock();
                dock.ID = "rd" + dr["ID"].ToString();
                dock.Title = "<div style=\"position:relative; top:7px; height:70px;\"><img class=\"galleryPhoto\" src=\"/properties/images/" + dr["ImgName"].ToString() + "\" /></div>";
                dock.EnableDrag = true;
                dock.DockMode = DockMode.Docked;
                dock.UniqueName = Guid.NewGuid().ToString();
                dock.EnableEmbeddedSkins = false;
                dock.Width = Unit.Pixel(100);
                dock.Height = Unit.Pixel(75);
                dock.DefaultCommands = Telerik.Web.UI.Dock.DefaultCommands.Close;
                 
                dock.ContentContainer.CssClass = "photoButtons";
 
                Button delete = new Button();
                delete.Text = "Delete";
                delete.CssClass = "deleteButton";
 
                delete.Command += new DockCommandEventHandler(DeletePhoto);
                delete.CommandArgument = dr["ID"].ToString();
                delete.CommandName = "DeletePhoto";
                delete.OnClientClick = "return confirm('Are you sure you want to delete this photo?')";
 
                dock.ContentContainer.Controls.Add(delete);
 
                RadDockLayout1.Controls.Add(dock);
                dock.Dock(rdz1);
            }
        }


How do I wire up a simple Button inside the RadDock to an Event Handler?
Slav
Telerik team
 answered on 11 Oct 2012
6 answers
207 views
We have an ASP.NET 4 web app and we are using RadSessionPageStateCompression by configuring it in the BrowserFile.browser file like this:

<browsers>
  <browser refID="Default">
    <controlAdapters>
      <adapter controlType="System.Web.UI.Page" adapterType="Telerik.Web.UI.RadSessionPageStateCompression, Telerik.Web.UI, Version=2011.2.712.40, Culture=neutral, PublicKeyToken=121fae78165ba3d4" />
    </controlAdapters>
  </browser>
</browsers> When working in just one tab in the browser ViewState is OK. When working in several tabs (IE 8/9, Chrome 14.x) part of the ViewState is lost. Can you advice what is wrong? Regards, alexander
David
Top achievements
Rank 1
 answered on 11 Oct 2012
3 answers
157 views
I have a web application which use telerik controls.
I'm using viewstate compression

In web.config:
-----------------
<httpModules>
            <add name="RadCompression" type="Telerik.Web.UI.RadCompression"/>
</httpModules>

 <modules runAllManagedModulesForAllRequests="true">
   <remove name="RadCompression" />
   <add name="RadCompression" type="Telerik.Web.UI.RadCompression"
    preCondition="integratedMode" />
  </modules>

In browser file:
------------------
 <browser refID="Default">
        <controlAdapters>
            <adapter controlType="System.Web.UI.Page"
                     adapterType="Telerik.Web.UI.RadHiddenFieldPageStateCompression"/>
           <!-- <adapter controlType="System.Web.UI.Page"
                     adapterType="Telerik.Web.UI.RadSessionPageStateCompression"/>-->
        </controlAdapters>            
    </browser>

The problem is when open a web page and do some actions like building a grid or filling RadComboBox, and then wait while doing nothing in the page (receive a call as i work in a call center and filling the data from this call) after about 10 minutes the page lost its data that has been filled (ComboBox items disappear and RagGrid rows disappear completely).

The page seems to be come from the server without running the load event at least.

This happened in many pages around the web application.

I Hope you can help me cause I'm stuck in it.

Thank you.
David
Top achievements
Rank 1
 answered on 11 Oct 2012
5 answers
56 views

I have the following code below At the top of the page I have a collapsible 
panel
within the panel is an ASP Accordion with a total of 5 ASP Accordion
panes.


When it runs it does a post back on the whole page and binds the info to the 
Rad Scheduler which is great.


But when I ajax the aspx page, first using ASP panels which didn't work
then using telerik:radAjaxPanels it stops
binding the appointments data to
the Rad Scheduler which I can't work out.

So when I remove the panels it works but when I add the panels it stops
working.

I want each pane to post back then for the rad scheduler to post back, 
instead of the whole page doing a post back of both controls.

Any Suggestions

Thanks - John M 

<asp:Accordion>
<asp:AccordionPane ID="AccordionPane1" runat="server"">
            <Content>
              <telerik:RadAjaxPanel ID="PanelStaff" runat="server" LoadingPanelID="RadAjaxLoadingPanel2">      
                   <asp:TextBox ID"StaffTextBox" runat="server"/>
                   <asp:Button ID="StaffSearchButton" runat="server"/>
             </telerik:RadAjaxPanel>
           </Content>
<asp:AccordionPane>
</asp:AccordionPane>
  
//I have 5 of these Accordion panes I want to have RadAjaxPanel in each Accordion pane.
  
<telerik RadScriptManager ID="Radscriptmanager1" runat="server">
<scripts>
</scripts>
</telerick:RadScriptManager>
  
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="RadScheduler1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="PanelStaff" LoadingPanelID="RadAjaxLoadingPanel2" />
                    <telerik:AjaxUpdatedControl ControlID="RadScheduler1" LoadingPanelID="RadAjaxLoadingPanel1" />
                    <telerik:AjaxUpdatedControl ControlID="RadToolTipManager1" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>
  
<telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server" LoadingPanelID="RadAjaxLoadingPanel1" HorizontalAlign="NotSet">
    <telerik:RadScheduler ID="RadScheduler1" >
    //Do Stuff
     </telerik:RadScheduler>
</telerik:RadAjaxPanel>



Ivana
Telerik team
 answered on 11 Oct 2012
1 answer
98 views
Hello,

I am trying to fix this issue since a few days, but I didn't find a solution. I hope you can help me.
I have a RadGrid and the Excel-Export worked fine. Then I put a RadAjaxPanel with RadAjaxLoadingPanel around it, and it stopped working. I have an asp:Button that starts the export. This button is in the panel too. I tried several solutions I found in this forum and the internet but none worked for me.

Either the error is like that:
The button-click exports the excel correct, but after that, the button is "dead". Nothing happens if you click it a second time. There are other controls in the panel (RadDatePicker) and they doesn't work too after the excel export.

Or the error is like that:
I click the export-button and then the loading icon appears. After a while it disappears but no excel is exported (but the controls are not "dead").

So either I have dead controls or nothing happens.

Does someone have an example code or a link for me?

I work in Sharepoint 2010 in a ModalDialog. Maybe this is why it is not working as expected?

Thank you!
Barbara
Top achievements
Rank 1
 answered on 11 Oct 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?