|
Hey guys, I've been having a lot of fun with the new DataGridView control! Right now, I'm trying to figure out how to build like a custom column/cell type. I need a cell that is sort of like a textbox. I'm bind a guid to it (CustomerID), but I want it to display the customer name. I also want to add some extra funtionality when the user clicks in the cell an modifiers the text. Any ideas where to start here?? |
| JonM Wednesday, September 21, 2005 5:06 PM |
The documentation now contains samples on creating a custom cell and column. Please check that out!
thanks, mark program manager microsoft |
| Mark Rideout Thursday, October 13, 2005 10:23 PM |
WinForms team is currently working on some white papers, some of which will discuss hosting controls in the data grid view control. Keep looking at "Windows Forms Sample Applications", the WinForms team will post an announcement once the white papers are ready. http://forums.microsoft.com/msdn/ShowForum.aspx?ForumID=67Hope this helps. Daniel. This posting is provided "as-is" |
| Daniel Herling - Student Wednesday, September 21, 2005 5:56 PM |
Any word on this whitepaper yet? even in a beta form? |
| JonM Wednesday, October 12, 2005 8:01 PM |
The documentation now contains samples on creating a custom cell and column. Please check that out!
thanks, mark program manager microsoft |
| Mark Rideout Thursday, October 13, 2005 10:23 PM |
Mark,
Where is the documentation/whitepaper on this? Right now, I'm using the RTM bits for VS2005 Pro and have not found anything searching the docs. Any ideas here? |
| JonM Monday, November 07, 2005 4:19 AM |
There are at least three samples (that I know of off the top of my head) in the docs for creating a custom cell/column. For a custom masked textbox cell/column, check out the following post: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=52363&SiteID=1For a custom button cell/column, check out the following topic: http://msdn2.microsoft.com/en-us/library/ms171619.aspxFor a sample on creating a custom calendar cell/column, check out the following topic: http://msdn2.microsoft.com/library/7tas5c80.aspxHope this helps! -mark DataGridView Program Manager Microsoft This post is provided "as-is" |
| Mark Rideout Monday, November 07, 2005 7:17 PM |
Just wondering if there is a good example on a custom cell painter that doesn't paint a standard type. For example, what if instead of wanting to display a property of an object in a cell, I want to display a whole object within a cell (say customer). The cell would then lay out the customer id and name appropriately. I previously wrote a grid to do this for me due to the shortcommings of the datagrid, this I named ObjectGrid since it allowed me to put any object within a cell easily. You can find this here (http://objectgrid.sourceforge.net/). Now I'm looking at the DataGridView and wanting to convert to using this control (standards, more fully complete), though a good example of using this grid for a custom data type is going to help. Kind Regards |
| Brett Ryan Monday, December 05, 2005 2:53 AM |
We don't have a sample yet that derives from DataGridViewCell, but the button sample here http://msdn2.microsoft.com/en-us/library/ms171619.aspx is a good start for a sample that doesn't paint regular stuff. Shortly we'll have a white paper that does a great job of describing all the "in's and out's" of creating a custom cell. -mark DataGridView Program Manager Microsoft This post is provided "as-is" |
| Mark Rideout Monday, December 05, 2005 6:16 PM |
Here is an example of Creating a Custom Percentage Column inDataGridView Control
DataGridView Custom Percentage Column
Regards,
Arsalan Tamiz
http://arsalantamiz.blogspot.com
|
| Arsalan Tamiz Wednesday, April 23, 2008 10:39 AM |