Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
81 views

Hi,

Is there a way to make the value the displayed selected value and still have the drop down show the text when selecting. My objective is to show a short version of the full description (e.g. TBA = To be announced). So when you open the drop down you see "To be Announced" and but the selection shows TBA. The reason is that we have limited space on the form and we want to keep the fields fairly narrow.

 

Thanks!

Aneliya Petkova
Telerik team
 answered on 14 Apr 2015
11 answers
960 views
Hi Team,

I need to clear RadGrid at client - side.
I tried this: masterTableView.get_filterExpressions().clear(); which cleared array holding filterExpressions but my filter values were preserved in filter textbox!
Radoslav
Telerik team
 answered on 14 Apr 2015
1 answer
298 views

I have a radgrid I am using to create what is essentially a dynamic crosstab where I create date columns across the top, based on calculations at runtime.  I know many of the column names at design and have tried both autogenerating columns and not.  Some columns i do not know until runtime (week start dates).  I'm trying to sum the number in those dynamically created week columns and having no luck.  What would be my best option??

 

my aspx: 

    <telerik:RadGrid ID="RadGrid1"  runat="server"  AllowSorting="True" AllowMultiRowSelection="false" AllowPaging="True" ShowGroupPanel="false" AutoGenerateColumns="false" GridLines="none" pagesize="500">
                     <MasterTableView ShowGroupFooter="true" UseAllDataFields="True">
                <GroupByExpressions>
                    <telerik:GridGroupByExpression>
                        <SelectFields>
                            <telerik:GridGroupByField FieldAlias="Team" FieldName="Team"  HeaderValueSeparator=": "></telerik:GridGroupByField>
                        </SelectFields>
                        <GroupByFields>
                            <telerik:GridGroupByField FieldName="Team" SortOrder="ascending"></telerik:GridGroupByField>
                        </GroupByFields>
                    </telerik:GridGroupByExpression>
                    <telerik:GridGroupByExpression>
                        <SelectFields>
                            <telerik:GridGroupByField FieldAlias="SkillRequired" FieldName="SkillRequired" HeaderValueSeparator=": "></telerik:GridGroupByField>
                        </SelectFields>
                        <GroupByFields>
                            <telerik:GridGroupByField FieldName="SkillRequired"></telerik:GridGroupByField>
                        </GroupByFields>
                    </telerik:GridGroupByExpression>
                </GroupByExpressions>
                <Columns>
                           
                </Columns>
            </MasterTableView>
            <ClientSettings ReorderColumnsOnClient="True" AllowDragToGroup="True" AllowColumnsReorder="True">
                <Selecting AllowRowSelect="True"></Selecting>
                <Resizing AllowRowResize="True" AllowColumnResize="True" EnableRealTimeResize="True"
                    ResizeGridOnColumnResize="False"></Resizing>
            </ClientSettings>
            <GroupingSettings ShowUnGroupButton="true"></GroupingSettings>
        </telerik:RadGrid>

 

 

 

My Code Behind:

 

   Protected Sub ProcessResources()
        'Add columns for the weeks between the to and from dates
        If IsDate([To].Text) And IsDate(From.Text) Then
            Dim MyRecords As DataSet = LoadResources([From].Text, [To].Text)
            Dim myWeeks As ArrayList = ReturnWeeks(From.Text, [To].Text)
            For i = 0 To myWeeks.Count - 1
                Dim myColumn As New DataColumn
                MyRecords.Tables("Resources").Columns.Add(myWeeks.Item(i))
                'changed columns to be autogenerated in order to attempt summation of hours 
                'Dim boundColumn As GridBoundColumn
                'boundColumn = New GridBoundColumn()
                'RadGrid1.MasterTableView.Columns.Add(boundColumn)
                'boundColumn.Aggregate = GridAggregateFunction.Sum
                'boundColumn.FooterText = "Sum of Hours:"
                'boundColumn.DataField = myWeeks.Item(i)
                'boundColumn.HeaderText = myWeeks.Item(i)
            Next
            'Iterate through myRecords and add hours where the task is in the range 
            Dim j As Integer
            For j = 0 To MyRecords.Tables("Resources").Rows.Count - 1
                Dim estimatedStart As Date = MyRecords.Tables("resources").Rows(j).Item("estimatedstartdate")
                Dim estimatedEnd As Date = MyRecords.Tables("resources").Rows(j).Item("estimatedenddate")
                Dim hours As Integer = MyRecords.Tables("resources").Rows(j).Item("esthours")
                Dim k As Integer
                For k = 0 To myWeeks.Count - 1
                    Dim weekstart As Date = myWeeks.Item(k)
                    Dim Weekend As Date = DateAdd(DateInterval.DayOfYear, 6, weekstart)
                    If estimatedStart <= Weekend And estimatedEnd >= weekstart Then
                        MyRecords.Tables("Resources").Rows(j).Item(weekstart) = hours
                    Else

                        MyRecords.Tables("Resources").Rows(j).Item(weekstart) = 0
                    End If

                Next
            Next
            MyRecords.Tables("Resources").Columns.Remove("EstimatedSTartDate")
            MyRecords.Tables("Resources").Columns.Remove("EstimatedEndDate")

            RadGrid1.DataSource = MyRecords.Tables("Resources")
            RadGrid1.DataBind()

End If
    End Sub

Eyup
Telerik team
 answered on 14 Apr 2015
5 answers
167 views
I’d like to create a list based on RadTreeList with different columns for nodes and their child nodes.  For example, I want to list all items that different shops have and therefore my parent node will be a shop with title, address, phone, url and child nodes are items it sells (title, price, quantity, rating, etc).

How can I do that or is there any workaround?

Ps. I wonder that in the “Pro Telerik ASP.NET and Silverlight Controls” book RadTreeList don’t even mentioned.

Regards,
Shamil
Konstantin Dikov
Telerik team
 answered on 14 Apr 2015
1 answer
91 views

Hi,

In Rad Editor when AutoResizeHeight="True", can not access content below big image.

It keeps flickering and shows top part of the content.

But in Google Chrome it is visible.

Best Regards,

Damodar

Dimitar
Telerik team
 answered on 13 Apr 2015
2 answers
153 views

Hi  guys... 

 

¿How i can put only the Header in the first page and Footer in the last Page when i export the Grid to PDF?

 

Thanks a lot.

 

currently version: 2013.2.717.40

Alertas
Top achievements
Rank 1
 answered on 13 Apr 2015
0 answers
102 views

So I have a RadContextMenu like below:

 

<telerik:RadContextMenu ID="rcMenuLoggedInUser" runat="server" EnableRoundedCorners="true" EnableShadows="true" OnItemClick="rcMenuLoggedInUser_ItemClick">
                   <Items>
                   <telerik:RadMenuItem Text="Settings" ImageUrl="~/Images/Settings_Blue.png" >
                                    <Items>
                                        <telerik:RadMenuItem Text="Client">
                                            <Items>
                                                <telerik:RadMenuItem Text="Add New Client" Value="Add New Client"></telerik:RadMenuItem>
                                                <telerik:RadMenuItem Text="Client List" Value="Client List"></telerik:RadMenuItem>
                                            </Items>
                                        </telerik:RadMenuItem>
                                        <telerik:RadMenuItem Text="User">
                                            <Items>
                                                <telerik:RadMenuItem Text="Add New User" Value="Add New User"></telerik:RadMenuItem>
                                                <telerik:RadMenuItem Text="User List" Value="User List"></telerik:RadMenuItem>
                                            </Items>
                                        </telerik:RadMenuItem>
                                    </Items>
                   </telerik:RadMenuItem>
                   <telerik:RadMenuItem Text="Profile" Value="Profile" ImageUrl="~/Images/Profile_Blue.png" />
                   <telerik:RadMenuItem Text="Logout" Value="Logout" ImageUrl="~/Images/Logout_Blue.png" />
                   </Items>
                   </telerik:RadContextMenu>

 

In the rcMenuLoggedInUser_ItemClick event in C#, I have case statements to detect which item was clicked and act upon that one.  This works fine the first time, but after that the OnItemClick event never fires again.  Now I should say, that this does work correctly on my local computer.  However, when I publish to my server where the website is housed, that is where it does not work. Once I publish and type in my URL to my website on my test server, the OnItemClick event only seems to fire one time.  If I try to click on any item after that first time, nothing happens.

 

Any idea as to what I am doing wrong?

 

Thanks,

 

Brad

Brad
Top achievements
Rank 1
 asked on 13 Apr 2015
1 answer
88 views
Hello,
I have problem with resources in Telerik scheduler custom template, to be specific InlineInsertTemplate.

I don't use separate ascx file for appointment layout.
Everything is in one aspx file and one cs file.

I can find the controls with resources and their values,in RadScheduler1_AppointmentCommand command insert I can put them inside a test label and the values are correct.
I make global public variables from resources so I should be able to add manually the resources but I tried many things and everything failed.

Main problem is i can not add resources. In default template everything works fine, resources are added to database.

Some of my tries:


protected void RadScheduler1_FormCreated(object sender, SchedulerFormCreatedEventArgs e)
    {
    if (e.Container.Mode == SchedulerFormMode.Insert)   
        {
    Resource resPracownik = new Resource();//i create manually resource
    resPracownik.Key = "Pracownik";
    resPracownik.Text = TextBoxPracownik.ToString();
    e.Appointment.Resources.Add(resPracownik);//this doesn't
    
    TextBox TitleTextBox = (TextBox)e.Container.FindControl("TitleTextBox");
    TitleTextBox.Text = e.Appointment.Subject;//this works

protected void RadScheduler1_AppointmentCommand(object sender, AppointmentCommandEventArgs e)
    {
    if (e.CommandName == "Insert"){
            RadComboBox RadComboBoxPracownik = (RadComboBox)e.Container.FindControl("RadComboBoxPracownik");//finding combobox withj resource value
            TextBox TextBoxPracownik = (TextBox)e.Container.FindControl("TextBoxPracownik");//finding hidden helping text box
            TextBoxPracownik.Text = RadComboBoxPracownik.SelectedItem.Value.ToString();//setting text box value same as combobox so i can easier bind it
            tempPracownik = RadComboBoxPracownik.SelectedItem.Value.ToString();//setting global variable
            
            Label1.Text = "status= " + tempStatus + "\npracownik= " + tempPracownik + "\ntyp= " + tempTyp;//this shows that the values are correct, the just dont bind
Plamen
Telerik team
 answered on 13 Apr 2015
3 answers
49 views

Hi Support Team / Telerik Users,

1 Source to 1 Destination is working fine,however the business requirement change and need to add another RadGrid control as another source. Any sample code for my issue?

 

Regards,

 Jok Garcia

Daniel
Telerik team
 answered on 13 Apr 2015
1 answer
116 views

I can drag a RadToolBarButton and drop it into a RadTextBox and have it drop where I want it to go without any code.

 I need to customize the text that is dropped.  By default, the NaviageUrl value is the text which is dropped into the RadTextBox.  How can I specify what the drop text is?

Here is my ASCX code.

 

<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="TSQLParamForm.ascx.cs" Inherits="WebApp.Controls.Forms.TSQLParamForm" %>
<telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server">
    <AjaxSettings>

        <telerik:AjaxSetting AjaxControlID="formulaTB">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="formulaTB" UpdatePanelCssClass="" />
                <telerik:AjaxUpdatedControl ControlID="AttributeToolBar" UpdatePanelCssClass="" />
            </UpdatedControls>
        </telerik:AjaxSetting>
        <telerik:AjaxSetting AjaxControlID="AttributeToolBar">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="formulaTB" UpdatePanelCssClass="" />
                <telerik:AjaxUpdatedControl ControlID="AttributeToolBar" UpdatePanelCssClass="" />
            </UpdatedControls>
        </telerik:AjaxSetting>

    </AjaxSettings>
</telerik:RadAjaxManagerProxy>


<telerik:RadTextBox runat="server" ID="formulaTB" Rows="5" MaxLength="4000" Width="100%" InputType="Text" RenderMode="Lightweight" TextMode="MultiLine">
</telerik:RadTextBox>
<telerik:RadToolBar runat="server" ID="AttributeToolBar" Width="100%" SingleClick="None">
    <Items>
        <telerik:RadToolBarButton runat="server" Text="@Attr1" Value="@Attr1" NavigateUrl="@Attr1">
        </telerik:RadToolBarButton>
        <telerik:RadToolBarButton runat="server" Text="@Attr2" Value="@Attr2" NavigateUrl="@Attr2">
        </telerik:RadToolBarButton>
    </Items>
</telerik:RadToolBar>

 

 

Ivan Danchev
Telerik team
 answered on 13 Apr 2015
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
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
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?