Click here to Skip to main content
15,919,749 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionReporting Service in Asp.net 2005 Pin
Member 31782792-Oct-08 21:02
Member 31782792-Oct-08 21:02 
AnswerRe: Reporting Service in Asp.net 2005 Pin
Sathesh Sakthivel3-Oct-08 3:03
Sathesh Sakthivel3-Oct-08 3:03 
QuestionDate Time picker [modified] Pin
member272-Oct-08 20:52
member272-Oct-08 20:52 
AnswerRe: Date Time picker Pin
acroitoriu2-Oct-08 21:29
acroitoriu2-Oct-08 21:29 
GeneralRe: Date Time picker Pin
Krazy Programmer2-Oct-08 21:40
Krazy Programmer2-Oct-08 21:40 
QuestionResponse.AddHeader() Pin
jhyn2-Oct-08 19:21
jhyn2-Oct-08 19:21 
AnswerRe: Response.AddHeader() Pin
acroitoriu2-Oct-08 21:19
acroitoriu2-Oct-08 21:19 
AnswerRe: Response.AddHeader() [modified] Pin
jhyn2-Oct-08 21:20
jhyn2-Oct-08 21:20 
QuestionExport image to excel Pin
saravanan052-Oct-08 19:09
saravanan052-Oct-08 19:09 
Questionhave a problem with sessions Pin
kheer2-Oct-08 18:33
kheer2-Oct-08 18:33 
AnswerRe: have a problem with sessions Pin
Sneha Bisht2-Oct-08 18:48
Sneha Bisht2-Oct-08 18:48 
GeneralRe: have a problem with sessions Pin
kheer2-Oct-08 18:57
kheer2-Oct-08 18:57 
GeneralRe: have a problem with sessions Pin
N a v a n e e t h2-Oct-08 22:29
N a v a n e e t h2-Oct-08 22:29 
AnswerRe: have a problem with sessions Pin
Brij2-Oct-08 19:02
mentorBrij2-Oct-08 19:02 
GeneralRe: have a problem with sessions Pin
Krazy Programmer2-Oct-08 21:39
Krazy Programmer2-Oct-08 21:39 
GeneralRe: have a problem with sessions Pin
N a v a n e e t h2-Oct-08 22:33
N a v a n e e t h2-Oct-08 22:33 
QuestionTotal Days of Month Pin
Socheat.Net2-Oct-08 17:28
Socheat.Net2-Oct-08 17:28 
AnswerRe: Total Days of Month Pin
Brij2-Oct-08 18:12
mentorBrij2-Oct-08 18:12 
GeneralRe: Total Days of Month Pin
Socheat.Net2-Oct-08 18:36
Socheat.Net2-Oct-08 18:36 
Questionfind checkbox in a nested controls(Panel -> DataList) Pin
Albert832-Oct-08 14:16
Albert832-Oct-08 14:16 
AnswerRe: find checkbox in a nested controls(Panel -> DataList) Pin
AlexeiXX32-Oct-08 16:24
AlexeiXX32-Oct-08 16:24 
QuestionRe: find checkbox in a nested controls(Panel -> DataList) Pin
Albert832-Oct-08 17:24
Albert832-Oct-08 17:24 
AnswerRe: find checkbox in a nested controls(Panel -> DataList) Pin
AlexeiXX33-Oct-08 4:21
AlexeiXX33-Oct-08 4:21 
QuestionRe: find checkbox in a nested controls(Panel -> DataList) Pin
Albert833-Oct-08 7:02
Albert833-Oct-08 7:02 
Thanks a lot. With the index it goes through the checkboxes that I have and not through the datalist items.

For example using your suggestion: this.inboxDL.Items[1]

CheckBox chkBox = (CheckBox)this.inboxDL.Items[1].FindControl("chkMarkerInbox");
Response.Write("check");
if (chkBox.Checked == true)
{
ddlTest.SelectedItem.Text = "works";
}

Only when I click on checkbox with index[1] ddlTest will change to "works".
But I have 5 more checkboxes which are not changing the state of ddlTest to "works".
So it goes through the checkboxes and not the datalist items as I understand.
Is it so?

But I made it work as follows. This way I assume when it encounter non checkbox controls it does nothing and when it does with Findcontrol it stores true/false in the isDeleted variable.
That's how I think the code works.

bool isDeleted = false;

foreach (DataListItem anItem in inboxDL.Items)
{
isDeleted =
((CheckBox)anItem.FindControl("chkMarkerInbox")).Checked;
if (isDeleted)
{
lbDel.Enabled = true;
ddlTest.SelectedItem.Text = "works";
}
}
Thanks again.
Questionplace a link in datalist to an image Pin
Meax2-Oct-08 12:07
Meax2-Oct-08 12:07 

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.