I have stuck with one problem.
I have asp.net application which uses Kendo UI for the presentation of data.
My client needs me to create one report which uses Kendo UI Grid for display data and it will also require some user input by using ASP.net controls like DropDownlist ,Datetime control , Checkbox and Div SHow hide.
Now, my question is, is it possible to add custom controls in the Kendo Grid?
Please reply I am really stuck with this
Read this to find out more about dropdownlists in Kendo UI grids. Read this to find out more about date pickers. Read this to find out more about checkboxes. So you can solve all of these, but you will get quicker responses in the future if you do not post composite questions, you have posted several problems in the same question. People do not answer it because they do not bother to solve all your problems in a single question.
Also, you might like to know that defining the column types of the grid's data model (not remember how, as my Kendo UI days are gone and I do not read my old code unless it is absolutely necessary) is a source of miracles.
I hope my post was helpful to you.
Related
I need a gridview such that when I click on a row to edit it, the data shows in a formview within that row. The user can then make updates within the formview. I am not able to find a suitable example that can do something like this. Can somebody please point me to an appropriate example that does this.
Note that I am using ASP.NET.
Thank you.
Here is an example from Kendo , You can download and use their tools for free with limited support.
Kendo Inline Editing Grid for ASP.Net
Please excuse me for a probably low quality of this question, since I'm not a web dev, so I possibly don't now some obvious things and don't know what to Google for. I think problem must have some simple solution, but I'm struggling with it for two days now, so I feel myself pretty stupid :-).
I have a custom control which is a set of checkboxes which are added dynamically based on a property which is set in OnLoad event of a page. I have two such controls on a page and second control items should be based on items selected in first control.
The problem is, I can't figure out, how to catch on autopostback which boxes were selected in first control before second contol is constructed to pass this data to it?
Take a look at this.
http://forums.asp.net/t/1440174.aspx
Since your building them dynamically, they are not as easy to find as webforms would like to be, if you added them to the page and wired up events and such.
Your going to look at the Request.Forms list, and search thru it for any controls you want.
I believe checkboxes are like radio buttons, they only return if they are checked, which is good, cause you want to know which ones were checked.
I've used same solution as in the accepted answer for this question: Dynamically Change User Control in ASP.Net , just need to assign an unique id for each dynamically created CheckBox in custom control. Not as clean solution as I want but at least it works.
You can save the data in the ViewState, QueryString or as Session before moving to the next page and you can do modifications based on it.
I'm considering going at this myself because my requirements are particular and highly customized:
The grid is bound to a
collection of complicated objects,
each of which may contain child and
grandchild objects. Depending on
data and context, the template'd
cells vary from TextBoxes to
ComboBoxes to Calendars to a
combination of controls.
TextBox cells have Google-style
auto-complete functionality. Also
each TextBox cell can expand into a
small TreeView pane that allows
hierarchy-navigating selection of a
value should auto-complete be
insufficient.
Values from other controls can be drag-and-dropped into cells.
Columns are re-sizable and re-orderable. Clicking their headers
sorts data.
All of the above is AJAX /
client-side / Web 2.0 of course.
Has anyone built anything similar from scratch? Or used an effective tool to accomplish this goal? How well would Telerik meet my specs? Is it right to have the hunch that something this specific is best done by taking a Microsoft GridView and extending it myself?
Thanks for your two cents.
If you have a SQL Server-based application, you could consider using ASP.NET Dynamic Data as a starting point. I have used it for the first time a few weeks ago and found it quire useful. It provides a lot of functionality, but you still can customise nearly everything. However, seeing your requirements you probably will have to customise a lot of things.
If you intend to use Telerik based on the specification you put forth, browse the online demos of their Ajax grid first. Most of the features are supported I think (some by integrating other Telerik controls in the grid like RadComboBox with auto-complete), for the rest you should count on your custom coding.
How to get started with using GridView in ASP.net?
grid view is pretty slick especially in asp.net. You can check all the gridview tutorials on ASP DATA TUTORIALS.. it is the perfect place to start learning asp.net. If you don't want to learn then you can always add a sql database, insert a grid view and connect it to the data base via a datasource. Then you can play around with it. However i will strongly recommend those tutorials as they contain all tips and tricks you want to know. You can ask more questions here, i will be glad to answer.
And I inherited from the GridView to create the GridViewTree - a multi-column treeview server control. So reviewing this might give you some other ideas.
It can be found here.
Well, I have a few blog posts on the GridView:
Multiple Row Selections with CheckBoxes.
Checking All Rows Using Client-Side Script.
Attaching upload files to a record.
Sort Column Arrow Performance.
How to Work With a GridView Row in JavaScript.
All can be found here.
What is the best method to display repeating data with slightly different controls or sub data? For example displaying an expanded list of questions and answers. Some questions will have answers, some will not. Some button controls would show for some items while not for others.
In classic ASP I've used XML/XSL quite effectively for displaying data in this manner. In .NET I've used functions being called from a label with the HTML writer class to render controls dynamically and nested list views that would bind or not depending on existing data.
I know I could also use XSL with .NET but my question is - is there a better method of displaying data this way? Inline IIf's and functions being called from the front end doesn't seem very clean.
I think the ListView would work in your situation:
http://blogs.msdn.com/mikeormond/archive/2008/01/23/some-asp-net-3-5-listview-control-examples.aspx
http://weblogs.asp.net/scottgu/archive/2007/08/10/the-asp-listview-control-part-1-building-a-product-listing-page-with-clean-css-ui.aspx
You have the ability to group items in different layouts using the ItemTemplates and you can also tap into the event handlers when loading the data.
EDIT:
You may be able to do it this way dynamically, but it's tricky with the ID's:
http://blogs.msdn.com/mikeormond/archive/2008/07/26/dynamically-loading-listview-templates.aspx
Or you could simply create a table composite control and build it up dynamically yourself...