Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
86 views

 

Hi,

I got an issue with ImageGalleryTemplateItem that can not be found - my version is 2014.2.618.40.

 

Regards,

 

Duy

Duy
Top achievements
Rank 1
 answered on 20 Sep 2016
1 answer
157 views

Hi Telerik Team,

I am using RadPageLayout to make pages responsive.Every page works fine except one case i.e When a Page is Opened in RadWindow. Actually it is detecting wrong Resolution/View port. I have read about Viewport breakpoints on http://docs.telerik.com/devtools/aspnet-ajax/controls/pagelayout/creating-responsive-design/viewport-breakpoints  and it Says:

Device type            Resolution     
 xs                          max-width: 360px 
sm                          min-width: 361px / max-width: 768px
md                          min-width: 769px / max-width: 1024px
lg                            min-width: 1025px / max-width: 1280px lg
xl                            min-width: 1281px extra large resolutions

but It seems that RadWindow does not follow these above breakpoints. I have noticed the breakpoints (in case of RadWindow) as below: 

Device type            Resolution    

xs         max-width: 376px
sm       min-width: 377px / max-width: 784px
md      min-width: 785px / max-width: 1040px
lg         min-width: 1041px / max-width: 1296px
xl         min-width: 1297px

Is there a way to fix this issue ?

Thank you

Sunil

Bozhidar
Telerik team
 answered on 20 Sep 2016
1 answer
299 views

My requirement is on pageload since I've nothing to bind to radgrid I need to just show the grid headers with "Add new row" button".
1.  When the user click the "Add new row' button a new row is created with 2 textboxes and 2 dropdown(binds data from the database) to the radgrid row. 
2. Each row should have remove row button
3. at the radgrid footer I've the Button "save to db"
4. after adding the  data to the new row(not saved yet to the db) i need to add more rows. When I click on "Add new row' button I lose all the data entered. Technically saying on postback losing all data. this part is where I need help on how to handle this. 

Finally after adding all rows I save the data to database.

*************Thoughout this functionality I have no data to rebind the radgrid from the database**************************

<telerik:RadGrid ID="RadGrid1" runat="server" AutoGenerateColumns="false" MasterTableView-CommandItemSettings-ShowAddNewRecordButton="false"  MasterTableView-CommandItemSettings-ShowRefreshButton="false" OnNeedDataSource="RadGrid1_NeedDataSource"
            OnItemDataBound="RadGrid1_ItemDataBound" OnItemCommand="RadGrid1_ItemCommand">
            <MasterTableView Width="100%" HeaderStyle-Font-Bold="true" CommandItemStyle-Font-Bold="true" DataKeyNames="IsAdd,CourseID"  CommandItemDisplay="Top" CommandItemStyle-HorizontalAlign="Right">
                <CommandItemTemplate>
                    <asp:Button ID="IsAdd" Font-Size="Small" Font-Bold="true" CommandName="InitInsert" Text ="Add Course" runat="server" />
 
                </CommandItemTemplate>
                <Columns>
                    <telerik:GridTemplateColumn UniqueName="CourseID" HeaderText="Course #" DataField="CourseID">
                        <ItemTemplate>
                           <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
                        </ItemTemplate>
                    </telerik:GridTemplateColumn>
                    <telerik:GridTemplateColumn UniqueName="CourseDept"  HeaderText="Course dept" DataField="DeptID">
                        <ItemTemplate>
                          <asp:DropDownList ID="DeptDropDown" DataField="DeptID" DataTextField="DeptName" runat="server" AutoPostBack="false"></asp:DropDownList>
                        </ItemTemplate>
                    </telerik:GridTemplateColumn>
                    <telerik:GridTemplateColumn UniqueName="LocationName" HeaderText="Course Location" DataField="LocationID">
                        <ItemTemplate>
                           <asp:DropDownList ID="locationDropDown" DataTextField="locationName" runat="server" AutoPostBack="false"></asp:DropDownList>              
                        </ItemTemplate>
                    </telerik:GridTemplateColumn>
                    <telerik:GridTemplateColumn UniqueName="Name" HeaderText="Remarks">
                        <ItemTemplate>
                       
                            <asp:TextBox ID="TextBox4" runat="server"></asp:TextBox>
                            <asp:Button ID="Button1" runat="server" Text="Remove Row" CommandName="Delete" />
                        </ItemTemplate>
                    </telerik:GridTemplateColumn>
                
                </Columns>             
                
            </MasterTableView>        
        </telerik:RadGrid
        <asp:Button ID="savebtn" runat="server" Font-Bold="true" Text="Save the course"/>
 
 
aspx.cs
 
 
protected void Page_Load(object sender, EventArgs e)
        {
            DataTable dt = new DataTable();        
             
            if (!IsPostBack)
            {
                 
                dt.Columns.Add("CourseID");
                dt.Columns.Add("Name");
                dt.Columns.Add("IsAdd");
 
                                 
                Session["dt"] = dt;
            }
        }      
 
 
        protected void RadGrid1_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
        {
            RadGrid1.DataSource = (DataTable)Session["dt"];
        }
 
 
        protected void RadGrid1_ItemDataBound(object sender, GridItemEventArgs e)
        {
            Button btn = new Button();         
 
            if (e.Item is GridDataItem)
            {
                GridDataItem item = e.Item as GridDataItem;
                TextBox TextBox1 = item.FindControl("TextBox1") as TextBox;
                Button Button1 = item.FindControl("Button1") as Button;               
               
(I've deptdropdown and locationdropdown binded here)
 
                 
                TextBox TextBox4 = item.FindControl("TextBox4") as TextBox;
 
                 
                bool isAdd = Convert.ToBoolean(item.GetDataKeyValue("IsAdd"));
                if (isAdd)
                {
                    TextBox1.Visible = LocationDropDown.Visible = DeptDropDown.Visible = TextBox4.Visible = true;
                    btn.Visible = true;
                    RadGrid1.DataSource = Session["dt"];
                }
               
            }
             
        }
 
       
        protected void RadGrid1_ItemCommand(object sender, GridCommandEventArgs e)
        {
            if (e.CommandName == RadGrid.InitInsertCommandName)
            {
                DataTable dt = (DataTable)Session["dt"];
                dt.Rows.Add(0, string.Empty, true);
                RadGrid1.MasterTableView.IsItemInserted = false;
                e.Canceled = true;
                RadGrid1.Rebind();
            }      
 
 
            }
        }

KIndly help me solve this. Provided the code below.

Kostadin
Telerik team
 answered on 20 Sep 2016
1 answer
113 views

Affected version: 2016.2.504.45

 

Steps to reproduce:

1) Create a RadGrid with a GridCalculatedColumn

2) Follow the first steps outlined in the documentation to put all rows in edit mode by calling Rebind() during prerender

 

Link: http://docs.telerik.com/devtools/aspnet-ajax/controls/grid/how-to/data-editing/put-all-items-in-edit-mode

 

3) Crash

 

Solution:

Follow the second steps outlined in the documentation to put all rows in edit mode via OnItemCreated

 

 

Konstantin Dikov
Telerik team
 answered on 20 Sep 2016
2 answers
245 views

Hi ,

I need a help regarding RadTreeView , where i would like wrap of Text value to next line according to fix size of text

Aspx Code 

 

<td valign="top" style="border: solid 1px #000000" class="style2">
                        <div id="scroll1" style="overflow: auto; height: 825px;width: 480px;">
                            <telerik:RadTreeView ID="rtvCardFileCatEntries" runat="server" OnNodeClick="rtvCardFileCatEntries_NodeClick"
                                OnNodeExpand="rtvCardFileCatEntries_NodeExpand" Skin="Telerik">
                                <CollapseAnimation Type="OutQuint" Duration="100"></CollapseAnimation>
                                <ExpandAnimation Duration="100"></ExpandAnimation>
                            </telerik:RadTreeView>
                        </div>
</td>

 

 

code-Cs page

 

 

rotected void rtvCardFileCatEntries_NodeClick(object sender, RadTreeNodeEventArgs e)
        {
            //If the click came from a Card file category 
            if (e.Node.Level == 1)
            {
                Guid selectedCardFileEntryId = Guid.Empty;
                try
                {
                    selectedCardFileEntryId = new Guid(e.Node.Value);
                }
                catch
                {
                }
                if (selectedCardFileEntryId != Guid.Empty)
                {
                    EntryEntity cardFileEntry = new EntryEntity(selectedCardFileEntryId);
                    ltCardFileEntryHtml.Text = cardFileEntry.EntryHtml; -- Here Text is coming 
                }
            }
        }

        protected void rtvCardFileCatEntries_NodeExpand(object sender, RadTreeNodeEventArgs e)
        {
            Guid selectedCardFileCategoryId = Guid.Empty;
            try
            {
                selectedCardFileCategoryId = new Guid(e.Node.Value);
            }
            catch
            {
            }
            if (selectedCardFileCategoryId != Guid.Empty)
            {
                Collection cardFileEntries = GetCardFileEntries(selectedCardFileCategoryId);
                e.Node.Nodes.Clear();
                foreach (EntryEntity cardFileEntry in cardFileEntries)
                {
                    RadTreeNode node = new RadTreeNode();
                    node.Text = cardFileEntry.Description;---Here Text is coming 
                    node.Value = cardFileEntry.CardFileEntryId.ToString();
                    e.Node.Nodes.Add(node);
                }
            }
        }

in UI --on click on button i am getting

eg:

Non-Commission Agencies
Wisconsin Department of Agriculture, Trade and Consumer Protection Agency

 

Now my requirement to change this above text to 

 

Non-Commission Agencies --Parent -on click of this (for parent also length of text 50 should come to next line)
Wisconsin Department of Agriculture,---rest text should come on next line(new line)-(length of text 50 should come to next line)

Trade and Consumer Protection Agency

 

 

what are possibilities please advise me .

 

Thanks in Advance 

 

 

 

 

Magdalena
Telerik team
 answered on 20 Sep 2016
3 answers
124 views

Hello I hope you can help me.

I am using Telerik RadHtmlChart, I need to remove from the x axis Saturdays and Sundays. What I mean, I need that the distance between friday and Monday be the same as Monday to Tuesday, my data will return only information for day weeks not for weekend.
It's possible?

Thank you very much in advance.

Vessy
Telerik team
 answered on 20 Sep 2016
4 answers
143 views

Hello I hope you can help me.

I am using Telerik RadHtmlChart, I need to remove from the x axis Saturdays and Sundays. What I mean, I need that the distance between friday and Monday be the same as Monday to Tuesday, my data will return only information for day weeks not for weekend.
It's possible?
Thank you very much in advance.

Vessy
Telerik team
 answered on 20 Sep 2016
1 answer
254 views
Hi, we are using RadAjaxManager in Master page and RadAjaxManagerProxy in Content Page where loading panel is not working. Below is the sample code for the same condition:

Master Page:
<telerik:RadAjaxManager ID="RadAjaxManager1" EnableAJAX="true" runat="server"></telerik:RadAjaxManager>
<asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server">            
</asp:ContentPlaceHolder>

Content Page:
    <telerik:RadCodeBlock ID="RCB1" runat="server">
        <script type="text/javascript">
            function Submit() {.....}
        </script>
    </telerik:RadCodeBlock>

<telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server">
        <AjaxSettings>        
            <telerik:AjaxSetting AjaxControlID="ajaxPanel1">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="ajaxPanel1" LoadingPanelID="RadAjaxLoadingPanel1" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManagerProxy>

    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
    </telerik:RadScriptManager>

<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" BackgroundPosition="Center" runat="server" Transparency="30" BackColor="#E0E0E0">
        <div>
            <asp:Image ID="Image1" runat="server" ImageUrl="~/Images/ajax-loader.gif" AlternateText="loading"></asp:Image>
        </div>
    </telerik:RadAjaxLoadingPanel>

Earlier we were not using RadAjaxManagerProxy and RadAjaxManager was implemented in Content Page only. After upgrading application to .Net framework 4.5 and telerik version to 2016.2.607.45, we included proxy and then this issue started occurring. Kindly help in the scenario how can we use loading panel through manager proxy?
Maria Ilieva
Telerik team
 answered on 20 Sep 2016
3 answers
523 views
hi,
i need enable and disable the item child of the radmenu depending on the data taken from a database.
For example...
into page aspx into page_load event or page_init, if there're not the record into database the item child witn value 2 must be disable.

this code radmanu is:
<telerik:RadMenu ID="RadMenu1" Runat="server"
EnableRoundedCorners="True" EnableShadows="True" Skin="Sunset">
<Items>
<telerik:RadMenuItem runat="server" Owner="RadMenu1" Text="Immagine profilo">
<Items>
<telerik:RadMenuItem runat="server" ImageUrl="~/Image/Icone/new.png" Owner=""
Text="Nuova" Width="110px" Value="1">
</telerik:RadMenuItem>
<telerik:RadMenuItem runat="server" ImageUrl="~/Image/Icone/view.png" Owner=""
Text="Visualizza" Width="110px" Value="2">
</telerik:RadMenuItem>
<telerik:RadMenuItem runat="server" ImageUrl="~/Image/Icone/delete.png"
Owner="" Text="Elimina" Width="110px" Value="3">
</telerik:RadMenuItem>
</Items>
</telerik:RadMenuItem>
</telerik:RadMenu>

how can i do it? with client side and use javascript or server side and use codce behind?
i use this code:

RadMenu1.Items(0).Items(1).Enabled = false

but into load event dont fuction. this code function only radmenu1_init event. But i must need that function in page_load event because there i load the record from database

 

Second problem i use the radwindows for load a new page and into this i save the record. When i close the radwindows, the item child with value 2 must be enable. So must tu use the javascript code?

Please help me

thanks you

Anton
Telerik team
 answered on 20 Sep 2016
6 answers
282 views
i want to set radtilelist in sequence either horizontally or vertically.  Cn u pls tell me. 
Stanimir
Telerik team
 answered on 20 Sep 2016
Narrow your results
Selected tags
Tags
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?