Click here to Skip to main content
15,896,290 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: how to write feedback form in asp.net v1.1 Pin
Talal Sultan8-Aug-07 3:47
Talal Sultan8-Aug-07 3:47 
QuestionQuery join probs.., Pin
Member 38798812-Aug-07 21:33
Member 38798812-Aug-07 21:33 
AnswerRe: Query join probs.., Pin
T.EDY2-Aug-07 22:22
T.EDY2-Aug-07 22:22 
AnswerRe: Query join probs.., Pin
Edwin Syarief2-Aug-07 23:07
Edwin Syarief2-Aug-07 23:07 
QuestionGrid View Header and Footer Pin
mpavas2-Aug-07 21:32
mpavas2-Aug-07 21:32 
AnswerRe: Grid View Header and Footer Pin
Talal Sultan2-Aug-07 21:55
Talal Sultan2-Aug-07 21:55 
GeneralRe: Grid View Header and Footer Pin
mpavas2-Aug-07 22:12
mpavas2-Aug-07 22:12 
AnswerRe: Grid View Header and Footer Pin
Talal Sultan2-Aug-07 22:28
Talal Sultan2-Aug-07 22:28 
Ok, if you're using the statement you wrote in the post, I believe it is normal that you get an "object not set" error.

You said that you use the following expression:

if (e.Row.RowType == DataControlRowType.DataRow) || (e.Row.RowType == DataControlRowType.Header)

This indicates that if the row is either a data row or a header do something. In case it is a header, there is no data in it and it might throw an error if you attempt to access something that is not there.

I have never used DataItem so I cannot tell you for sure but what I'm sure of is that I use the following and it works very well:

GridViewRow row = e.Row;
if (row.RowType == DataControlRowType.Header)
{
  // do something
}

if (row.RowType == DataControlRowType.DataRow)
{
  // do something
}


It could help if you post more code to see exactly what is written.

Talal





"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning."
--Rich Cook

GeneralRe: Grid View Header and Footer Pin
mpavas2-Aug-07 22:59
mpavas2-Aug-07 22:59 
GeneralRe: Grid View Header and Footer Pin
Talal Sultan2-Aug-07 23:15
Talal Sultan2-Aug-07 23:15 
GeneralRe: Grid View Header and Footer Pin
mpavas2-Aug-07 23:39
mpavas2-Aug-07 23:39 
QuestionCreate notepad in runtime asp.net Pin
praveenkumar_mca2-Aug-07 21:11
praveenkumar_mca2-Aug-07 21:11 
AnswerRe: Create notepad in runtime asp.net Pin
Christian Graus2-Aug-07 21:26
protectorChristian Graus2-Aug-07 21:26 
AnswerRe: Create notepad in runtime asp.net Pin
Edwin Syarief2-Aug-07 23:13
Edwin Syarief2-Aug-07 23:13 
Questionconver the c# code to corresponding vb.net code Pin
biswa472-Aug-07 20:43
biswa472-Aug-07 20:43 
AnswerRe: conver the c# code to corresponding vb.net code Pin
Christian Graus2-Aug-07 21:33
protectorChristian Graus2-Aug-07 21:33 
AnswerRe: conver the c# code to corresponding vb.net code Pin
Imran Khan Pathan2-Aug-07 23:31
Imran Khan Pathan2-Aug-07 23:31 
Questionneed validation Expression string Pin
Imran Khan Pathan2-Aug-07 20:19
Imran Khan Pathan2-Aug-07 20:19 
AnswerRe: need validation Expression string Pin
Christian Graus2-Aug-07 20:25
protectorChristian Graus2-Aug-07 20:25 
AnswerRe: need validation Expression string Pin
Anurag Gandhi2-Aug-07 22:26
professionalAnurag Gandhi2-Aug-07 22:26 
GeneralRe: need validation Expression string Pin
Imran Khan Pathan2-Aug-07 23:33
Imran Khan Pathan2-Aug-07 23:33 
AnswerRe: need validation Expression string Pin
shweta@syscom2-Aug-07 23:07
shweta@syscom2-Aug-07 23:07 
GeneralRe: need validation Expression string Pin
Imran Khan Pathan2-Aug-07 23:35
Imran Khan Pathan2-Aug-07 23:35 
Questionsession time out Pin
praveenkumar_mca2-Aug-07 20:09
praveenkumar_mca2-Aug-07 20:09 
AnswerRe: session time out Pin
Christian Graus2-Aug-07 20:15
protectorChristian Graus2-Aug-07 20:15 

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.