Columns.width - API Reference - Kendo UI Grid - Documentation
Có thể bạn quan tâm
- Kendo UI for jQuery
Product Bundles
DevCraft
All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:
- NEW: Design Kits for Figma
- Online Training
- Document Processing Library
- Embedded Reporting for web and desktop
Web
Kendo UI UI for jQuery UI for Angular UI for React UI for Vue UI for Blazor UI for ASP.NET Core UI for ASP.NET MVC UI for ASP.NET AJAXMobile
UI for .NET MAUI UI for XamarinDocument Management
Telerik Document ProcessingDesktop
UI for .NET MAUI UI for WinUI UI for WinForms UI for WPFReporting
Telerik Reporting Telerik Report ServerTesting & Mocking
Test Studio Test Studio Dev Edition Telerik JustMockCMS
SitefinityUI/UX Tools
ThemeBuilder Design System Kit Templates and Building BlocksDebugging
Fiddler Fiddler Everywhere Fiddler Classic FiddlerCap FiddlerCoreFree Tools
VB.NET to C# Converter Testing FrameworkView all products
- Overview
- Frameworks
- jQuery
- Angular
- React
- Vue
- Demos
- Roadmap
- What's New
- Roadmap
- Release History
- Docs & Support
Support and Learning
- Support and Learning Hub
- First Steps
- Docs & Demos
- Virtual Classroom
- Forums
- Feedback Portal
- Blogs
- Accessibility and Security
- Submit a Ticket
- Trust Center
Productivity and Design Tools
- ThemeBuilder
- Design System Documentation
- Visual Studio Code Extensions
- Embedded Reporting
- Pricing
- Shopping cart
- Contact Us
- Try now
- Search in Documentation
- Search in Knowledge Base
- Search in API Reference
columns.width String|Number
The width of the column. Numeric values are treated as pixels. The width option supports the fundamental measuring units. For instance:
- px sets the width in pixels
- cm sets the width in centimeters
- mm sets the width in millimeters
- % sets the width relative to the grid's element width
- em sets the width relative to the font-size of the grid's element width
- rem sets the width relative to font-size of the root element
For more important information, please refer to Column Widths.
Grid options, including column widths, can be set programmatically after Grid initialization with the setOptions method.
Example - set the column width as a string
<div id="grid"></div> <script> $("#grid").kendoGrid({ columns: [ { field: "name", width: "200px" }, { field: "age" } ], dataSource: [ { name: "Jane Doe", age: 30 }, { name: "John Doe", age: 33 } ] }); </script>Example - set the column width as a number
<div id="grid"></div> <script> $("#grid").kendoGrid({ columns: [ { field: "name", width: 200 }, { field: "age" } ], dataSource: [ { name: "Jane Doe", age: 30 }, { name: "John Doe", age: 33 } ] }); </script> In this article Related articles Not finding the help you need? Contact Support Improve this articleGetting Started
- Getting Started
- Demos
- Whats New
- Roadmap
Community
- Forums
- Blogs
- Feedback Portal
- Doc Contribution
Frameworks
- Kendo UI for jQuery
- Kendo UI for Angular
- Kendo UI for React
- Kendo UI for Vue
Copyright © 2024 Progress Software Corporation and/or its subsidiaries or affiliates. All Rights Reserved.
Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.
- Terms of Use
- Privacy Center
- Security Center
- Trademarks
- License Agreements
- Code of Conduct
- Doc Copyright
Từ khóa » Html.kendo().grid Column Width
-
ASP.NET MVC Data Grid Component Column Widths - Documentation
-
How To Set Column Width To Autofit In Kendo Grid MVC - Stack Overflow
-
Kendo-ui-core/grid-autofit-all-columns- At Master - GitHub
-
Auto Fit Column In Kendo Grid - C# Corner
-
How To Set A Max-width Property To Individual Kendo Grid Columns
-
Kendo Grid Column Width + Scrollable - ITecNote
-
How To Set Width Of The Columns In Percentage | JQuery - EjGrid
-
Kendo Grid Column Width + Scrollable
-
Min Column Width In Kendo Grids - ADocLib
-
Kendo Grid Automatically Fit Column Width Excep...anycodings
-
Kendo Grid With Fixed Column - JSFiddle - Code Playground
-
Enforce Minimum Column Width Grid - Popular Blocks
-
Kendo Grid MVC Wrapper Automatic Column Configuration
-
CSS Grid-template-columns Property - W3Schools