Select table row with checkBox
Select table row with checkBox
I want to be able to select a row(s) in a table by having a checkBox in the first column of a table, similar to DataGridViewCheckBoxColumn for DataGrids. But the equivalent is not available in ODGridColumn, so no way to achieve this in OD (at least not with ODGrids), right?
Cheers,
Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA
Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA
Re: Select table row with checkBox
An example of how you can manually do such a thing is in FormSheetImport.cs The real magic of it all is in gridMain_CellClick() and the FillGrid().
The best thing about a boolean is even if you are wrong, you are only off by a bit.
Jason Salmon
Open Dental Software
http://www.opendental.com
Jason Salmon
Open Dental Software
http://www.opendental.com
Re: Select table row with checkBox
OK. Cool.
Thanks Jason
Thanks Jason
Cheers,
Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA
Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA
Re: Select table row with checkBox
Well, I tried to do what you suggested, but either my question was not clear enough or I what I want can't be done with OD grids because I could not figure out a way to get checkboxes to appear in the first row of an OGrid to select a row from your explanation. I think what you're doing is different from what I want.
So I resorted to Windows DataGrids, but as they they say of Jake from State Farm "She looks hideous"

Is there any way to duplicate what I've done in an ODGrid?
So I resorted to Windows DataGrids, but as they they say of Jake from State Farm "She looks hideous"

Is there any way to duplicate what I've done in an ODGrid?
Cheers,
Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA
Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA
Re: Select table row with checkBox
Not currently. You would have to add a lot of functionality to the ODGrid to get a physical check box in the grid. Let me rephrase that, it would be EASY to get the check box in the grid, it would be HARD to associate the check box to the object (or simply the row). We have a text box (procedure code window, fee column) that you can look at for inspiration if your heart is set on having the physical check box within the grid.wjstarck wrote:Is there any way to duplicate what I've done in an ODGrid?
Otherwise, the example I mentioned above makes a simple cell act like a check box (listens for click events inside a specific cell) and simply displays an 'X' when checked or blanks the cell out when not "checked". Then at the end, on OK click or something, it loops through all rows and takes action on any row (or object if using row.Tag) that has the 'X' present.
The best thing about a boolean is even if you are wrong, you are only off by a bit.
Jason Salmon
Open Dental Software
http://www.opendental.com
Jason Salmon
Open Dental Software
http://www.opendental.com
Re: Select table row with checkBox
Great that helps thanks as always Jason.
Cheers,
Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA
Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA