Click here to Skip to main content
15,907,395 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Creating Microsoft Powerpoint presentation dynamically Pin
Avanika Gupta14-Aug-06 1:13
Avanika Gupta14-Aug-06 1:13 
AnswerRe: Creating Microsoft Powerpoint presentation dynamically Pin
seee sharp14-Aug-06 22:12
seee sharp14-Aug-06 22:12 
AnswerRe: Creating Microsoft Powerpoint presentation dynamically Pin
Sathesh Sakthivel14-Aug-06 2:25
Sathesh Sakthivel14-Aug-06 2:25 
Questionproblem with frames Pin
prabhakar dwivedi13-Aug-06 18:47
prabhakar dwivedi13-Aug-06 18:47 
AnswerRe: problem with frames Pin
coolestCoder13-Aug-06 20:41
coolestCoder13-Aug-06 20:41 
QuestionPDF to TXT/RTF/DOC Pin
Sathiyaraj Ganesan13-Aug-06 18:18
Sathiyaraj Ganesan13-Aug-06 18:18 
AnswerRe: PDF to TXT/RTF/DOC Pin
RaghuSanta21-Aug-06 21:44
RaghuSanta21-Aug-06 21:44 
QuestionDisplaying Summary Data in the Footer Pin
blurMember13-Aug-06 16:17
blurMember13-Aug-06 16:17 
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaspp/html/GridViewEx03.asp[^]

The article link is abit wrong. The link is on GridView Examples for ASP.NET 2.0: Displaying Summary Data in the Footer. I am using .NET 2.0 C# and had learn from that article to display summary data in the footer.

    protected void GridView4_RowDataBound(object sender, GridViewRowEventArgs e)<br />
    {<br />
        if (e.Row.RowType == DataControlRowType.DataRow)<br />
        {<br />
            absentTotal += Convert.ToInt32(DataBinder.Eval(e.Row.DataItem, "Category"));<br />
        }<br />
        else if (e.Row.RowType == DataControlRowType.Footer)<br />
        {<br />
            e.Row.Cells[0].Text = "Total Absent:";<br />
            e.Row.Cells[3].Text = absentTotal.ToString("c");<br />
<br />
            e.Row.Font.Bold = true;<br />
        }<br />
    }


I then forgetten that my data values for Category is a string values "A", "P" etc. How can I achieved similar way of calculating the row for Category meaning calculating how many A's and P's. Perhaps the footer of the gridview would show:

Total Absent (A): 5
Total Present (P): 10

thanks in advance. Much appreciated.

QuestionHow to export a table to excel? Pin
steven_wong13-Aug-06 16:12
steven_wong13-Aug-06 16:12 
AnswerRe: How to export a table to excel? Pin
Ramasubramaniam15-Aug-06 3:41
Ramasubramaniam15-Aug-06 3:41 
QuestionHow to use a list control and a pop up calendar together? Pin
frossie13-Aug-06 15:48
frossie13-Aug-06 15:48 
QuestionQuestion about Context.User Pin
devboycpp13-Aug-06 12:03
devboycpp13-Aug-06 12:03 
AnswerRe: Question about Context.User Pin
minhpc_bk13-Aug-06 15:39
minhpc_bk13-Aug-06 15:39 
GeneralRe: Question about Context.User Pin
devboycpp14-Aug-06 1:57
devboycpp14-Aug-06 1:57 
QuestionRe: Question about Context.User Pin
devboycpp14-Aug-06 6:00
devboycpp14-Aug-06 6:00 
AnswerRe: Question about Context.User Pin
minhpc_bk14-Aug-06 16:18
minhpc_bk14-Aug-06 16:18 
QuestionChat-Room with Asp.net 1.1 and VB Pin
chrissivol13-Aug-06 11:52
chrissivol13-Aug-06 11:52 
AnswerRe: Chat-Room with Asp.net 1.1 and VB Pin
steven_wong13-Aug-06 16:18
steven_wong13-Aug-06 16:18 
QuestionHelp - DotNetNuke website setup Pin
karanjsingh13-Aug-06 11:49
karanjsingh13-Aug-06 11:49 
QuestionGridView - RenderControl with skin bug ? Pin
Tee+13-Aug-06 9:11
Tee+13-Aug-06 9:11 
QuestionConvert Doc To XML Pin
Mansurali13-Aug-06 8:45
Mansurali13-Aug-06 8:45 
Questioninsert data in a dropdownlist from another web page Pin
galatia13-Aug-06 8:11
galatia13-Aug-06 8:11 
AnswerRe: insert data in a dropdownlist from another web page Pin
_AK_20-Aug-06 23:51
_AK_20-Aug-06 23:51 
QuestionCount website guests Pin
TheEagle13-Aug-06 4:45
TheEagle13-Aug-06 4:45 
AnswerRe: Count website guests Pin
_AK_20-Aug-06 23:49
_AK_20-Aug-06 23:49 

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.