Telerik Forums
Kendo UI for jQuery Forum
2 answers
578 views
I am having trouble changing the styling on the Select button in the upload tool.
The Upload button has taken the correct style, but the Select does not.

I have attached code samples of the css, html, and javascript, as well as a screen shot of the rendered result.

In Chrome it looks like the button has the correct styles, but they do not render on screen.
Drew Auman
Top achievements
Rank 1
 answered on 28 May 2013
1 answer
120 views
I has a grid with many column,and I set the grid overflow-x:scroll,but it seems that that the pager not to automatic lengthening when I  drag to scroller? How to make the pager  flow to right more closely?

@(Html.Kendo().Grid(Model)

      .Name("StudentGrid")

      .Columns(columns =>

      {

        columns.Bound(p => p.Name).Title("Name").Width(200);

          columns.Bound(p => p.Age).Title("Age").Width(200);

       columns.Bound(p => p.Name).Title("Name").Width(200);

          columns.Bound(p => p.Age).Title("Age").Width(200);

      columns.Bound(p => p.Name).Title("Name").Width(200);

          columns.Bound(p => p.Age).Title("Age").Width(200);

        columns.Bound(p => p.Name).Title("Name").Width(200);

          columns.Bound(p => p.Age).Title("Age").Width(200);

      })

      .Navigatable()

      .Groupable()

      .Pageable()

      .DataSource(dataSource => dataSource

                                   
.Ajax()

                                   
.PageSize(50)

                                   
.Read(read => read.Action("GetStudentImfo", "Student"))



      ).AutoBind(false)

      .Resizable(resize => resize.Columns(true)))



and the css style:

#StudentGrid {
    overflow-x: scroll;
}
Dimo
Telerik team
 answered on 28 May 2013
3 answers
162 views
My problem is that everytime i use the .Filterable it is refreshing . . 


Controller:

public partial class ApplicantController : Controller
    {
        Entities context = new Entities();

        public ActionResult Index()
        {
            return View();
        }
        public ActionResult GetApplicant([DataSourceRequest] DataSourceRequest request)
        {
                IQueryable<APPLICANT> applicants = context.APPLICANTs;
                DataSourceResult result = applicants.ToDataSourceResult(request);
                return Json(result,JsonRequestBehavior.AllowGet);
    
        }

        public ActionResult UpdateApplicant([DataSourceRequest] DataSourceRequest request, APPLICANT applicant)
        {
            var applicantToUpdate = context.APPLICANTs.First(app => app.APPLICANT_ID == applicant.APPLICANT_ID);

            TryUpdateModel(applicantToUpdate);

            context.SaveChanges();

            return Json(ModelState.ToDataSourceResult(),JsonRequestBehavior.AllowGet);
        }
        public ActionResult InsertApplicant([DataSourceRequest] DataSourceRequest request, APPLICANT addappli)
        {
            if (ModelState.IsValid)
            {
                context.APPLICANTs.Add(addappli);
                context.SaveChanges();
            }

            return Json(new[] { addappli }.ToDataSourceResult(request));
        }
}


Index : 

@using Kendo.Mvc.UI
@(Html.Kendo().Grid<_2ndApplicantKendo.Models.APPLICANT>()
    .Name("grid")
    .ToolBar(tb => tb.Create())
        .Columns(columns =>
        {
        columns.Bound(p => p.APPLICANT_LastName).Width(130);
        columns.Bound(p => p.APPLICANT_FirstName).Width(130);
        columns.Bound(p => p.APPLICANT_MiddleName).Width(130);
        columns.Bound(p => p.APPLICANT_Address).Width(130);
        columns.Bound(p => p.APPLICANT_City).Width(130);
        columns.Bound(p => p.APPLICANT_Phone).Width(160);
        columns.Bound(p => p.APPLICANT_Email).Width(160);
         columns.Command(cmd =>
          {
              cmd.Edit();
            
          });
    })
        .Filterable()
        .Groupable()
        .Pageable(page => page.Enabled(true).PageSizes(new Int32[] { 10, 20, 40 }))
        .Scrollable()
        .Editable(a => a.Mode(GridEditMode.PopUp))
        .DataSource(dataSource => dataSource.Ajax()
        .Model(model => model.Id(c => c.APPLICANT_ID))
        .Read("GetApplicant", "Applicant")
        .Update("UpdateApplicant", "Applicant" )
        .Create("InsertApplicant", "Applicant")))

           
            


Dimiter Madjarov
Telerik team
 answered on 28 May 2013
3 answers
414 views
I'm trying to learn to use the Kendo grid.
So I went to  http://demos.kendoui.com/web/grid/index.html
Where the Basic Usage shows columns First Last City Title Birthdate

And here is the code for that under index.cshtml.

@model IEnumerable<Kendo.Mvc.Examples.Models.ProductViewModel>

@(Html.Kendo().Grid(Model)
.Name("Grid")
.Columns(columns =>
{
columns.Bound(p => p.ProductID).Groupable(false);
columns.Bound(p => p.ProductName);
columns.Bound(p => p.UnitPrice);
columns.Bound(p => p.UnitsInStock);
})
.Groupable()
.Pageable()
.Sortable()
.Scrollable()
.Filterable()
.DataSource(dataSource => dataSource
.Ajax()
.Read(read => read.Action("Products_Read", "Grid"))
)
)

I'm finding your MVC docs obtuse enough without this kind of help.

Same story on Binding to remote data.
The DataSource calls an read method that isn't in the Remote_DataController.cs

I really want to love your product..  So help me out fix the documentation.

Pat NH USA
Atanas Korchev
Telerik team
 answered on 28 May 2013
6 answers
2.6K+ views
Here is what I am trying to do.
From one view I allow the user to create a new record, let's call it Employee.  When the record is created (server side) I want to be able to pass the newly created database Id so that when I display the list of Employees in a Kendo UI grid which is populated via Ajax() call; I want to "pre" select the newly created row.  

I have not seen any good example of how to do this, especially in an ASP.NET MVC environment.
Josh
Top achievements
Rank 1
 answered on 28 May 2013
0 answers
57 views
How to delete my question,I have post a new question and want to delete the old?
xi
Top achievements
Rank 1
 asked on 28 May 2013
2 answers
741 views
Hello,

Once created, many Kendo components root DOM element are wrapped under new HTML elements.  Any class of the original input will also be copied to some parent elements.

Ex:


1.<input type="text" class="MyClass" />

Notice kendo added the MyClass to the span wrapper at line #1 and #3 once the DateTimePicker is created.

1.<span class="k-widget k-datetimepicker k-header MyClass" style="width: 200px;">
2.    <span class="k-picker-wrap k-state-default">
3.        <input id="mydatetimepicker" style="width: 100%;" data-role="datetimepicker" type="text" class="k-input MyClass" role="textbox" aria-haspopup="true" aria-expanded="false" aria-disabled="false" aria-readonly="false" aria-label="Current focused date is 5/22/2013 9:50:42 AM">
4.        <span unselectable="on" class="k-select">
5.            <span unselectable="on" class="k-icon k-i-calendar" role="button" aria-controls="datetimepicker_dateview">select</span><span unselectable="on" class="k-icon k-i-clock" role="button" aria-controls="datetimepicker_timeview">select</span>
6.        </span>
7.    </span>
8.</span>

When you access the root input (line #3) with the ID, there's no problem.

1.$('#mydatetimepicker')
2.//Will return the input of line 3

However, if you want to use the class, then is getting more tricky.

1.$('.MyClass')
2.//Will return the span of line 1 and the input of line 3

As each widget (DateTimePicker, DropDownList, ComboBox...) are wrapped differently, it might be a good idea to add a class to the root input that would allow us to spot the input we are looking for?
Simon
Top achievements
Rank 1
 answered on 28 May 2013
7 answers
435 views
Hi, 
I have scrollable Kendo grid which must fill in entire browser window (currently Chrome).

I need the vertical scrollbar to be frozen (not disappear) when I scroll to the right with the horizontal scrollbar. Also the command buttons to be frozen when I scroll to the left 

Please see the attached pictures.

Thank you in advance

Shabtai
Shabtai
Top achievements
Rank 1
 answered on 28 May 2013
5 answers
688 views
HI, we got a javascrip program that parse an html file in memory and then do some work on it and add the element to the active DOM. 
When I try to convert an <select></select> contained in a jQuery variable in a KendoDropDown list, a strange thing append.

if I use the "normal way" to convert the select in KendoDropdown. In this case the <select> is aleready in the active DOM:
<select id="testSel">
</select>
 
$('#testSel').kendoDropDownList();
I got this result:
<span class="k-widget k-dropdown k-header" style="" unselectable="on" role="listbox" aria-haspopup="true" aria-expanded="false" tabindex="0" aria-owns="testSel_listbox" aria-disabled="false" aria-readonly="false" aria-busy="false">
   <span class="k-dropdown-wrap k-state-default" unselectable="on">
      <span class="k-input" unselectable="on"> </span>
      <span class="k-select" unselectable="on">
           <span class="k-icon k-i-arrow-s" unselectable="on">select</span>
      </span>
   </span>
   <select id="testSel" data-role="dropdownlist" style="display: none;"></select>
</span>

Now, if I try to convert it from memory:
$srcElem.kendoDropDownList();
where $srcElem is a jQuery DOM object that containt 
<select id="test2Sel" data-acteur="SELTHEME"></select>
I got this result in the active DOM:
<select id="test2Sel" data-acteur="SELTHEME">
    <select id="test2Sel" data-acteur="SELTHEME" data-role="dropdownlist" style="display: none;"></select>
</select>
I am doing someting wrong... 
Dimo
Telerik team
 answered on 28 May 2013
1 answer
115 views
Hi!

So, I have a Grid on my project like this:

<iframe width="100%" height="300" src="http://jsfiddle.net/JnP8M/32/embedded/" allowfullscreen="allowfullscreen" frameborder="0"></iframe>

I want to update the MyGlobalVars.GridData locally.
I can see that when the user clicks "save changes", an array of the changed data gets passed to the function.
If I want to update MyGlobalVars.GridData am I supposed to do it manually? Or is there some kind of way to sync it?

Thanks.
Alexander Valchev
Telerik team
 answered on 27 May 2013
Narrow your results
Selected tags
Tags
Grid
General Discussions
Charts
Data Source
Scheduler
DropDownList
TreeView
MVVM
Editor
Window
DatePicker
Spreadsheet
Upload
ListView (Mobile)
ComboBox
TabStrip
MultiSelect
AutoComplete
ListView
Menu
Templates
Gantt
Validation
TreeList
Diagram
NumericTextBox
Splitter
PanelBar
Drag and Drop
Application
Map
ToolTip
Calendar
PivotGrid
ScrollView (Mobile)
Toolbar
TabStrip (Mobile)
Slider
Button (Mobile)
Filter
SPA
Drawing API
Drawer (Mobile)
Globalization
LinearGauge
Sortable
ModalView
Hierarchical Data Source
Button
FileManager
MaskedTextBox
View
Form
NavBar
Notification
Switch (Mobile)
SplitView
ListBox
DropDownTree
PDFViewer
Sparkline
ActionSheet
TileLayout
PopOver (Mobile)
TreeMap
ButtonGroup
ColorPicker
Pager
Styling
Chat
MultiColumnComboBox
Dialog
DateRangePicker
Checkbox
Timeline
Drawer
DateInput
ProgressBar
MediaPlayer
ImageEditor
TextBox
OrgChart
Accessibility
Effects
PivotGridV2
Licensing
ScrollView
Switch
TextArea
BulletChart
QRCode
ResponsivePanel
Wizard
CheckBoxGroup
Localization
Barcode
Breadcrumb
Collapsible
MultiViewCalendar
Touch
RadioButton
Stepper
Card
ExpansionPanel
Rating
RadioGroup
Badge
Captcha
Heatmap
AppBar
Loader
Security
TaskBoard
Popover
DockManager
TimePicker
FloatingActionButton
CircularGauge
ColorGradient
ColorPalette
DropDownButton
TimeDurationPicker
ToggleButton
BottomNavigation
Ripple
SkeletonContainer
Avatar
Circular ProgressBar
FlatColorPicker
SplitButton
Signature
Chip
ChipList
VS Code Extension
AIPrompt
PropertyGrid
Sankey
Chart Wizard
OTP Input
SpeechToTextButton
InlineAIPrompt
StockChart
ContextMenu
DateTimePicker
RadialGauge
ArcGauge
AICodingAssistant
SmartPasteButton
PromptBox
SegmentedControl
+? more
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?