Telerik Forums
Kendo UI for jQuery Forum
1 answer
216 views
I am looking at using a background image to use on the window.  

I currently would like to put an image as a background and make it about A4 size so if someone wishes to print it, then it could be possible. However even if I reference an image off the internet it still does not show, however the colour does.  

I have tried to simply use your kendo window mvc demo code but no luck. I have added a Div referenced test to simply add an image 

Do you have any ideas?

Thanks

@(Html.Kendo().Window()
    .Name("window")
    .Title("About Alvar Aalto")
    .Content(@<text>

<div class="test">
        <p>
            Alvar Aalto is one of the greatest names in modern architecture and design.
            Glassblowers at the iittala factory still meticulously handcraft the legendary
            vases that are variations on one theme, fluid organic shapes that let the end user
            ecide the use. Interpretations of the shape in new colors and materials add to the
            growing Alvar Aalto Collection that remains true to his original design.
        </p>

        <p>
            Born Hugo Alvar Henrik Aalto (February 3, 1898 - May 11, 1976) in Kuortane, Finland,
            was noted for his humanistic approach to modernism. He studied architecture at the
            Helsinki University of Technology from 1916 to 1921. In 1924 he married architect
            Aino Marsio.
        </p>

        <p>
            Alvar Aalto was one of the first and most influential architects of the Scandinavian
            modern movement, and a member of the Congres Internationaux d'Architecture Moderne.
            Major architectural works include the Finlandia Hall in Helsinki, Finland,
            and the campus of Helsinki University of Technology.
        </p>

        <p>
            Source:
            <a href="http://www.aalto.com/about-alvar-aalto.html" title="About Alvar Aalto">www.aalto.com</a>
        </p>
    </div>
    </text>)
    .Draggable()
    .Resizable()
    .Width(600)
    .Actions(actions => actions.Pin().Minimize().Maximize().Close())
    .Events(ev => ev.Close("onClose"))
)

<span id="undo" style="display:none" class="k-button">Click here to open the window.</span>

<script>
    function onClose() {
        $("#undo").show();
    }

    $(document).ready(function() {
        $("#undo").bind("click", function() {
                $("#window").data("kendoWindow").open();
                $("#undo").hide();
            });
    });
</script>

<style scoped>
    #example
    {
        min-height:500px;
    }

    #undo {
        text-align: center;
        position: absolute;
        white-space: nowrap;
        padding: 1em;
        cursor: pointer;
    }
   
    .test
    {
background-image:url("http://blog.felho.hu/wp-content/debuggingsuckststingrocks.png");
background-color:#cccccc;
width:200px;
height:200px;
}

</style>
Dimo
Telerik team
 answered on 19 Sep 2013
1 answer
379 views
We have an ASP.NET MVC application using jQuery Unobtrusive Validation and NumericTextBox. We are seeing some odd behavior with respect to the automatic field highlighting that the validation provides.

The NumericTextBox generates a <span> with two <input type="text"> elements inside. One appears to be the formatted/read-only version of the input; the other appears to be the actual input box the user types in.

jQuery Unobtrusive Validation assigns the CSS class "input-validation-error" to any input field with a client-side validation error. The problem is, it only assigns it to the box that the user types into. So while the field has focus, you see a nice border on the field as expected (see attachment: cursor_in_field.png). However, when the user moves to a different field, while the validation message stays present, the field border is lost because the input field is technically hidden (see attachment: cursor_out_of_field.png).

Further, if client-side validation passes but some server-side validation fails, you get a "double border" around the field - because the <span> element gets the CSS class "input-validation-error" AND the input elements (both) get the class (see attachment: server_val_fail.png).

If you put the cursor into the field and take it back out again, the client-side validation fires and removes the "input-validation-error" class from the two input elements... but the span element doesn't get cleaned up (see attachment: server_val_fail_after_click.png).

I have the kendo.aspnetmvc.js and the kendo.web.js being included in my project. The behavior of the controls otherwise seems to work very well. Am I missing something?
Georgi Krustev
Telerik team
 answered on 19 Sep 2013
1 answer
897 views
 My page have two grids called grid1,grid2,I only want to style the grid1,not grid2.I use the css style in the header like  this,but  it seems that both grid changed.
.k-grid td {
color:red;
  padding: 0px;
   }

I try to write like this,but failed.
.GridTd {
color:red;
  padding: 0px;
    }
$("#grid1 td").addClass("GridTd "); //failed,I debug with firebug and find that the td style is used by default style(.k-grid td),not GridTd Style.
$("#grid1 k-grid   td").addClass("GridTd ");// faied


.k-grid td {    border-style: solid;    border-width: 0 0 0 1px;    line-height: 1.6em;    overflow: hidden;  
 padding: 0.4em 0.6em;   text-overflow: ellipsis;    vertical-align: middle;}.
GridTd {  color:red;   padding: 0;}
Dimo
Telerik team
 answered on 19 Sep 2013
1 answer
97 views
Is it possible to add an image to the chart title?

/Jakob
Hristo Germanov
Telerik team
 answered on 19 Sep 2013
1 answer
342 views
I'm using the Web kendo grid with the options: pageable, scrollable, filterable and sortable all set to true and selectable set to multiple, row (see below)
 I've extended the grid with a checkbox selection column (through some event handling) which all works like a charm and improves the usability for touch devices by allot.

On desktop (mouse input) all works very nice. But on touch devices the instinct of people is to "Swipe to scroll" to browse through the grid. But since selectable is set to multiple, row (which i believes causes this behavior) this is no longer possible. A selection of displayed rows is made during a Swipe causing users to be forced to use the scrollbar (Very bad usability)

Is there a way to keep the multiple row selection option but without drag/swipe selection (through Ctrl/Shift clicks) so "Swipe to scroll" remains possible

grid = new kendo.ui.Grid(
                gridContainer,
                {
                    columns: columns,
                    dataSource: dataSource,
                    selectable: "multiple, row",
                    pageable: true,
                    scrollable: true,
                    filterable: true,
                    sortable: true,
                    change: function () {
                       // some code regarding selection column
                    },
                    dataBound: function() {
                        // some code regarding selection column
                    }
                }
            );
Alexander Valchev
Telerik team
 answered on 19 Sep 2013
1 answer
219 views
I am trying to open a modal dialog using $("#modalview-message").kendoMobileModalView("open"); it works on IE but not on chrome? Why is that happening?
Alexander Valchev
Telerik team
 answered on 19 Sep 2013
3 answers
566 views
I have the following view:

<div data-role="view" style="background: green;" id="tabstrip-card" data-init="cardViewInit" data-title="My card" data-layout="mobile-tabstrip">
      content goes here
</div>

I've tried various things to get a background color on my view (actually want a background image), without any luck. I can put a div inside the view div and set it's height/width and apply a background to that, but that seems a bit unnecessary. Is there a way I can get a background on the view itself?

bally
Top achievements
Rank 1
 answered on 19 Sep 2013
1 answer
66 views
I am trying to set the pageSize dynamically. If i do:
localStorage.getItem('pageSize') || 10,

i do not have a problem.

But if i do:
pageSize: function () {           
                    return parseInt(localStorage.getItem('pageSize')) || 10;             
            },

the data-source gets reloaded multiple times and NaN appears on the bottom of the grid - page NaN of 100 instead of 1 of 100


Thanks
Atanas Korchev
Telerik team
 answered on 19 Sep 2013
3 answers
106 views
When tabbing into a numeric text box, on the webkit browsers when you 'tab' into a numeric text box (with default value of 0), the cursor gets inserted after the 0. Given a table with 3 columns of numeric boxes 3-tab-4-tab-5 yields 3,4,5 as the leading zero just gets dropped. In IE, because the cursor goes after the zero,  3-tab-4-tab-5 yields 30,40,50.  I have tried the latest release and stable, and the bug persists.

I know I can select the text when focusing the numeric box using the hack here. But is there a way to make IE behave like the other browsers without selecting the text?

Kiril Nikolov
Telerik team
 answered on 19 Sep 2013
1 answer
208 views
Does anyone know how to bind a kendo grid to a html table using Razor syntax?  I have seen 

$("#grid").kendoGrid({
height: 430,
sortable: true
});

put nothing for the Razor syntax.
Nikolay Rusev
Telerik team
 answered on 19 Sep 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
LLM Kit
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?