Click here to Skip to main content
16,011,120 members
Home / Discussions / C#
   

C#

 
Generalwindows service in c# Pin
omkamal6-Mar-02 4:14
omkamal6-Mar-02 4:14 
GeneralRe: windows service in c# Pin
8-May-02 12:27
suss8-May-02 12:27 
GeneralDeclarative Code Access Security Pin
6-Mar-02 3:58
suss6-Mar-02 3:58 
General**** The DataGrids! All of them! Pin
Domenic Denicola6-Mar-02 3:21
Domenic Denicola6-Mar-02 3:21 
GeneralRe: **** The DataGrids! All of them! Pin
James T. Johnson6-Mar-02 13:05
James T. Johnson6-Mar-02 13:05 
GeneralRe: **** The DataGrids! All of them! Pin
Domenic Denicola6-Mar-02 13:39
Domenic Denicola6-Mar-02 13:39 
GeneralRe: **** The DataGrids! All of them! Pin
James T. Johnson6-Mar-02 14:52
James T. Johnson6-Mar-02 14:52 
GeneralRe: **** The DataGrids! All of them! Pin
Domenic Denicola6-Mar-02 15:08
Domenic Denicola6-Mar-02 15:08 
James T. Johnson wrote:
Handling the ColumnChanging event lets you determine if a change should be allowed (if you don't want to allow the change throw an exception in the event handler).

Ahhh, so that's what's happening to my current code. It seems after I handle a deletion of a value, whenever I call DataTable.Columns.Remove(...) to reflect the invalidation of the row and update the columns accordingly, my ColumnChanged event handler is never called again. Ah, my code is way too messy anyway, it's prolly a good thing I'm redoing it.


So, does this sound like a good plan? I just iterate through the rows every time columnchanging is called, determine the valid ones, rebuild my data structure using those, and then rebuild my datagrid from my datastructure.

And how to decide between ColumnChanged and ColumnChanging? It seems ColumnChanged is called everytime the cursor moves out of the box or the data is otherwise accepted, which seems more appropriate than ColumnChanging, which is called whenever the column's value changes at all. I dunno, I'll work on it on the weekend when all this homework slows down Big Grin | :-D

-Domenic Denicola- [CPUA 0x1337]
MadHamster Creations

"I was born human. But this was an accident of fate - a condition merely of time and place. I believe it's something we have the power to change..."

GeneralRe: **** The DataGrids! All of them! Pin
James T. Johnson6-Mar-02 15:36
James T. Johnson6-Mar-02 15:36 
GeneralErrors & Exceptions in C# Pin
Anand Amirineni5-Mar-02 13:05
Anand Amirineni5-Mar-02 13:05 
GeneralRe: Errors & Exceptions in C# Pin
James T. Johnson5-Mar-02 15:50
James T. Johnson5-Mar-02 15:50 
GeneralRe: Errors & Exceptions in C# Pin
7-Mar-02 18:17
suss7-Mar-02 18:17 
QuestionHow to store an object into a database? Pin
5-Mar-02 9:17
suss5-Mar-02 9:17 
AnswerRe: How to store an object into a database? Pin
James T. Johnson5-Mar-02 10:06
James T. Johnson5-Mar-02 10:06 
AnswerRe: How to store an object into a database? Pin
James T. Johnson6-Mar-02 10:20
James T. Johnson6-Mar-02 10:20 
GeneralRe: How to store an object into a database? Pin
AndyG6-Mar-02 18:26
AndyG6-Mar-02 18:26 
Generalhelp in treeview needed Pin
4-Mar-02 22:38
suss4-Mar-02 22:38 
GeneralRe: help in treeview needed Pin
Anand Amirineni5-Mar-02 14:12
Anand Amirineni5-Mar-02 14:12 
QuestionHow to use SSL Pin
Felix Nielsen4-Mar-02 9:19
Felix Nielsen4-Mar-02 9:19 
QuestionHow to sublass visually a C# class Pin
4-Mar-02 6:03
suss4-Mar-02 6:03 
AnswerRe: How to sublass visually a C# class Pin
James T. Johnson4-Mar-02 14:12
James T. Johnson4-Mar-02 14:12 
GeneralRe: How to sublass visually a C# class Pin
5-Mar-02 3:19
suss5-Mar-02 3:19 
GeneralRe: How to sublass visually a C# class Pin
James T. Johnson5-Mar-02 7:37
James T. Johnson5-Mar-02 7:37 
GeneralRe: How to sublass visually a C# class Pin
6-Mar-02 2:44
suss6-Mar-02 2:44 
GeneralRe: How to sublass visually a C# class Pin
James T. Johnson6-Mar-02 9:02
James T. Johnson6-Mar-02 9:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.