Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
1.0K+ views

Hi All

Am recently starting to work with Kendo Grid (i'm new to MVC) and had the following requirement.

1) A tool bar that contains the Save and Cancel Button, as well as a filter for months

So i did the following

.ToolBar(toolbar =>
        {
            toolbar.Save();
            toolbar.Template(@<text>
                <div class="toolbar">
                    <label class="fismonth-lable" for="fiscalmonth">Show fiscal months:</label>
                        @(Html.Kendo().DropDownList()
                            .Name("fiscalmonth")
                            .OptionLabel("All")
                            .AutoBind(false)
                            .Events(e => e.Change("fiscalmonthChange"))
                            .HtmlAttributes(new { style = "width:150px;" })
                            .DataSource(ds =>
                            {
                                ds.Read("Toolbar_FiscalMonth", "Home");
                            })
                        )
                </div>
        </text>);
        })

But only the dropdown showed up. Am i missing something?

 

Secondly, i have a Boolean column that i wish to be displayed and edited as a checkbox. This is what i did

columns.Bound(p => p.IsSelectedForValidation).Filterable(false).Title("").ClientTemplate("<input type='checkbox' #= IsSelectedForValidation? checked='checked' : '' #  id='#=ID#'></input>").Width(30);

It does show as a checkbox, and i can check and uncheck it, but the "real" editing will still take place as a dropdown of "true/false". Am i missing something?

 

Thank you so much for your kind help.

 

Regards,

Su Ming

Su Ming
Top achievements
Rank 1
 answered on 28 Apr 2016
2 answers
159 views

Hello,

please help me!

I need set the TextBox no-editable when the row is in EditMode but editable when iadd a new row

here it is a part of my code:

<telerik:GridTemplateColumn HeaderStyle-Width="150px" UniqueName="txtID" HeaderText="ID del Servicio">
                                <ItemTemplate>
                                    <%# Eval("IdServicio") %>
                                </ItemTemplate>
                                <EditItemTemplate>
                                    <asp:TextBox runat="server" ID="textID" Text='<%# Eval("IdServicio") %>' width="145px" ReadOnly="true"/>
                                    <asp:RequiredFieldValidator runat="server" ControlToValidate="textID" />
                                    <asp:CompareValidator runat="server" ControlToValidate="textID" Operator="DataTypeCheck" Type="Integer" />
                                </EditItemTemplate>
                            </telerik:GridTemplateColumn>

Hansel Eduard
Top achievements
Rank 1
 answered on 28 Apr 2016
2 answers
115 views

some years ago I remember a handy "getting started" pdf that had walkthroughs of RadGrid development,specifically I recall master-detail development (hierarchy). Is that still available somewhere?

 

Incidently some of the demo links are broken - http://demos.telerik.com/aspnet-ajax/errorpageresources.aspx?aspxerrorpath=/aspnet-ajax/grid/examples/hierarchy/declarative-relations/defaultcs.aspx

 

 

Pavlina
Telerik team
 answered on 27 Apr 2016
1 answer
150 views

I am using the resource file to localize the Radfilter, everything is working except for the Preview Provider.    What is the Name of the Operator to use in the resource file if there is one.

French Preview :     (Prénom Égal à 'abc' AND Nom Égal à 'abc')

English Preview:      (Firstname Equal to 'abc' AND LastName Equal to 'abc')

 

Chi

 

 

 

Pavlina
Telerik team
 answered on 27 Apr 2016
3 answers
325 views
I am using the RadDateInput control.  If I key in a date such as, 2/33/2008, the date is highlighted in red.  How can I also display an error message?  I would like to use something like the ValidationSummary and RequiredFieldControl controls in ASP.Net.  Is there something similar in telerik or should I just go on and use the ASP.Net validation controls?

Thanks,
Bob
Viktor Tachev
Telerik team
 answered on 27 Apr 2016
1 answer
106 views

Hi, I have a client rowclick event and also a checkbox column - how do you use both together without the checking causing a rowclick event - or how do I determine the column clicked inside the rowclick so I can ignore the event when it is in the checkbox column.

Regards

Jon

 
Viktor Tachev
Telerik team
 answered on 27 Apr 2016
1 answer
260 views
I have a popup(telerik radwindow) which is in iframe.And i want that popup to be opened at the center of the screen and not at the center of iframe.
If I scroll the page it should reamain at the center of the screen.
Thanx in advance
Marin Bratanov
Telerik team
 answered on 27 Apr 2016
1 answer
251 views

Hi,

I've got a RadHtmlChart that is displayed as a radar chart.  I want to make it so that the labels around the outside, follow the same angle as their corresponding x-axis.  As far as I have been able to work out, I can only change the angle of all of the labels at one time.  What I currently have is:

 

<telerik:RadHtmlChart ID="RadHtmlChart1" runat="server" DataSourceID="sqlGetResults" Legend-Appearance-Visible="false" Height="100%" Width="100%" PlotArea-XAxis-DataLabelsField="QUESTION" PlotArea-XAxis-LabelsAppearance-Step="1" PlotArea-XAxis-StartAngle="45">
            <Appearance>
            </Appearance>
            <PlotArea>
                <XAxis Visible="True" StartAngle="45">                    
                </XAxis>
                <YAxis Visible="True">
                </YAxis>
            </PlotArea>
        </telerik:RadHtmlChart>

 

Any help would be greatly appreciated.

Kind regards,

Dan

Vessy
Telerik team
 answered on 27 Apr 2016
1 answer
143 views

I need help understanding a couple of code blocks got from the demo but it works 

1) got this code from the demo. It works. I just don't understand how it works. What does the Dictionary does (ELI5)

protected void RadSearchBox1_Search(object sender, SearchBoxEventArgs e)
{
    RadSearchBox searchBox = (RadSearchBox)sender;
    string JobOrderNumber = string.Empty;
    string likeCondition;
    if (e.DataItem != null)
    {
        JobOrderNumber = ((Dictionary<string, object>)e.DataItem)["JobOrderNumber"].ToString();
        if (!string.IsNullOrEmpty(JobOrderNumber))
        {
            likeCondition = string.Format("'{0}{1}%'", searchBox.Filter == SearchBoxFilter.Contains ? "%" : "", ((Dictionary<string, object>)e.DataItem)["JobOrderNumber"].ToString());
            SqlDataSource1.SelectCommand = "SELECT [JobOrderIndex], [JobOrderNumber], [JobOrderDate], [JobOrderStatus], [ProfitCenter], [JobType]" + "FROM[Bak-JobOrder] WHERE [" + searchBox.DataValueField + "] LIKE " + likeCondition;
            RadGrid1.DataBind();
        }
    }
}

2) I added a scenario using the UI in visual studio. I Master/Detail scenario which is similar to this demo.

What does this code do?

        

protected void Page_PreRender(object sender, EventArgs e)
{
    if (RadGrid1.SelectedIndexes.Count == 0)
        RadGrid1.SelectedIndexes.Add(0);
    if (RadGrid2.SelectedIndexes.Count == 0)
    {
        RadGrid2.Rebind();
        RadGrid2.SelectedIndexes.Add(0);
    }
}
 
protected void RadGrid1_ItemCommand(object sender, GridCommandEventArgs e)
{
    RadGrid2.SelectedIndexes.Clear();
}

Konstantin Dikov
Telerik team
 answered on 27 Apr 2016
4 answers
210 views

So,I have an HtmlChart that I'm using for some graphs a client of mine needs. I've managed to get everything done up just so, but I noticed when I looked at the tooltip for the points,that the points appear to be plotted in the wrong location. (See image)

I've double-checked that the tooltip is showing the correct values for the points. But as you can see in the image, the points are off.

 

Any help with this is greatly appreciated.

Ianko
Telerik team
 answered on 27 Apr 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?