Click here to Skip to main content
15,885,309 members
Home / Discussions / C#
   

C#

 
AnswerRe: How to send mail using SMTP Pin
eggie52-Jan-04 8:20
eggie52-Jan-04 8:20 
AnswerRe: How to send mail using SMTP Pin
Mazdak2-Jan-04 8:31
Mazdak2-Jan-04 8:31 
AnswerRe: How to send mail using SMTP Pin
Heath Stewart2-Jan-04 9:14
protectorHeath Stewart2-Jan-04 9:14 
GeneralRe: How to send mail using SMTP Pin
gr8tushar2-Jan-04 19:44
gr8tushar2-Jan-04 19:44 
GeneralRe: How to send mail using SMTP Pin
Heath Stewart2-Jan-04 19:47
protectorHeath Stewart2-Jan-04 19:47 
QuestionHOW TO Create a Summary Row For a Windows Form DataGrid by Using C# ???? Pin
zfeng_my2-Jan-04 3:02
zfeng_my2-Jan-04 3:02 
AnswerRe: HOW TO Create a Summary Row For a Windows Form DataGrid by Using C# ???? Pin
Mazdak2-Jan-04 3:46
Mazdak2-Jan-04 3:46 
AnswerRe: HOW TO Create a Summary Row For a Windows Form DataGrid by Using C# ???? Pin
Heath Stewart2-Jan-04 5:45
protectorHeath Stewart2-Jan-04 5:45 
This has been asked before, and as I told the previous person, you should consider using Label controls below the DataGrid. If you have a data-bound DataGrid and programmatically add a row, you must do so to the DataGrid.DataSource, which will add the row. If you then update that data source (say, to a database or XML file), it will contain that summary row. This is hardly what you want, I assume.

So, just use some values below it. That's what we do in our application, and there are many other benefits as well. First, it separates the summary of columns making it easier to see, and it doesn't scroll or resize like a DataGrid could, thus hiding certain summations. Second, one rarely needs to summarize ALL fields (for example, how would you summarize a name field for a person, company, etc.?), so just include enough labels to summarize what you need.

To summarize columns, just enumerate the rows and keep track of what you need to, then assign that value (or whatever) to a label that shows the value (or, if you use one label for the text label and value, use String.Format or something to assign the "Label: Value", "Label=Value", or whatever format to the Label.Text property).

 

-----BEGIN GEEK CODE BLOCK-----
Version: 3.21
GCS/G/MU d- s: a- C++++ UL@ P++(+++) L+(--) E--- W+++ N++ o+ K? w++++ O- M(+) V? PS-- PE Y++ PGP++ t++@ 5 X+++ R+@ tv+ b(-)>b++ DI++++ D+ G e++>+++ h---* r+++ y+++
-----END GEEK CODE BLOCK-----
GeneralArgumentException at building Pin
Peter Reiter1-Jan-04 23:26
Peter Reiter1-Jan-04 23:26 
GeneralRe: ArgumentException at building Pin
Mazdak1-Jan-04 23:50
Mazdak1-Jan-04 23:50 
GeneralRe: ArgumentException at building Pin
Peter Reiter2-Jan-04 0:17
Peter Reiter2-Jan-04 0:17 
GeneralRe: ArgumentException at building Pin
Mazdak2-Jan-04 1:42
Mazdak2-Jan-04 1:42 
GeneralRe: ArgumentException at building Pin
Peter Reiter2-Jan-04 3:23
Peter Reiter2-Jan-04 3:23 
Generalexclude private members in docs Pin
sridhar_india1-Jan-04 23:17
sridhar_india1-Jan-04 23:17 
GeneralRe: exclude private members in docs Pin
Heath Stewart2-Jan-04 5:36
protectorHeath Stewart2-Jan-04 5:36 
GeneralRe: exclude private members in docs Pin
sridhar_india5-Jan-04 23:51
sridhar_india5-Jan-04 23:51 
GeneralRe: exclude private members in docs Pin
Heath Stewart6-Jan-04 2:15
protectorHeath Stewart6-Jan-04 2:15 
GeneralRe: exclude private members in docs Pin
sridhar_india6-Jan-04 19:15
sridhar_india6-Jan-04 19:15 
GeneralReading Image from Office Applications Pin
amohammed1-Jan-04 23:12
amohammed1-Jan-04 23:12 
GeneralRe: Reading Image from Office Applications Pin
Heath Stewart2-Jan-04 5:33
protectorHeath Stewart2-Jan-04 5:33 
GeneralRe: Reading Image from Office Applications Pin
amohammed2-Jan-04 5:46
amohammed2-Jan-04 5:46 
GeneralRe: Reading Image from Office Applications Pin
Heath Stewart2-Jan-04 6:07
protectorHeath Stewart2-Jan-04 6:07 
GeneralRe: Reading Image from Office Applications Pin
amohammed2-Jan-04 5:46
amohammed2-Jan-04 5:46 
QuestionHow to create dynamic rectangle on window form? Pin
kseema1-Jan-04 22:19
kseema1-Jan-04 22:19 
AnswerRe: How to create dynamic rectangle on window form? Pin
Mazdak1-Jan-04 22:50
Mazdak1-Jan-04 22:50 

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.