1)Can we show only limited specified fields of the object binded along with some unbounded columns(like check box for selection). How to state to show only few and not all the fields of the binded object.
2) Once the grid is binded to any generic collection, can we add a new object of the same type to the grid to create a new row.(Is it mandatory that the collection should implement IBindingList, if not it throws expection when trying to add a new object/row ). What is the best way to add a new row in this scenario.
Also, the newly added row should be able to have selectable combobox, datetime and other controls to select right option for the column, which can then be individually captured to set for the corresponding object of the row.
Note: I may not need this comobox in same cell of other rows. Something like, all other rows be noneditable and only the newly added row cells are editable and once the focus is lost, its made uneditable.
How can I place controls like RichTextBox, datetimeEditor, ComboBox into the cells.
This is a major point of focus, any code example will be appreciated.
3) Handling sorting.
I see there is a SortChanging event, which gives the new header values for sort.
As our DB is huge and we implement our own custom sorting along with pagination, we would like to handle the sort.
Isn't there any SortHandled property in this event as we dont want to make e.cancel, doing which it doesnt show the sort indicators.
4) Hierarchy : How to achive heirarchy with
a) Collection of objects (for which we can have heirarchy condition)
b) DataSet
5) An example of showing that individual cells can accept different controls like checkboxes, combobox, datetime, image editors etc.,
6) Any Printing option from the grid.
7) Any Paging : Like many of the webgrid does when binded to DB.
8) Some kind of RowInitialised event, where in we can set that row cells to be editable/ non editable or row to be visible/hidden.
Help for the points with an example code will be very helpfull so as to know if RadGridView can be used in our project.
Thanks in advance.
Arif
ThemeResolutionService.RegisterThemeFromStorage(ThemeStorageType.Resource, "Program.Resources.ApplicationTheme.xml"); |
ThemeResolutionService.ApplicationThemeName = "ApplicationTheme"; |
OK, the title's a little bit of a lie.
I am unable to figure out the right combination of property values and event handlers to get a behavior I need for dragging things around in a radtreeview.
I want to allow users to drag node around in the tree (not into other controls). This would seem to be very easy by simply setting the AllowDragDrop property to true. This works great -- except that I need to implement some constraints. Specifically, each type of node knows whether a given other node can be dropped onto it.
I was unable to find any event I could effectively hook to implement this. The documentation suggests that at the end when the drop happens (DragEnding) it's possible to apply some logic to determine if the drop is valid. However this is not enough for me. I want to provide real time feedback when the user is hovering over various nodes about whether they can drop there.
So I started trying tsome things. First I tried adding some feedback in the DragOver event. But as soon as I did that, the visuals provided by the control (basically the bitmap being dragged around) moved a few pixels but then froze. I finally concluded that I was colliding with the fully automatic drag drop capabilities in the control enabled by setting AllowDragDrop.
So I turned off AllowDragDrop and initiated a DoDragDrop manually on the MouseMove event. Then I started implementing the other normal Windows events (like DragOver). In order to provide feedback, I change the colors of the potential target node. This all works well *BUT* I can't figure out how to catch when the user cancels the drag-drop so I can restore the node to its original colors. I can do this if the operation completes by changing it back in the DragDrop event, but I don't think that happens if the user hits escape while dragging.
So... I thought I could hook QueryContinueDrag because it seems to have a flag indicating whether the user pressed Escape. And here's the problem. The event never seems to be called. Is that a bug? Is there something I need to do to cause the events to be fired? My concern is that there is a bug such that QueryContinueDrag doesn't fire if the drag-drop operation is manually initiated (as I'm doing now).
Any advice? Is there a simpler way to make this work? Is there a bug with firing QueryContinueDrag?
Help!
Thanks,
David