p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum.

Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Professional section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.

Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old May 14th, 2007, 04:50 AM
Friend of Wrox
Points: 970, Level: 12
Points: 970, Level: 12 Points: 970, Level: 12 Points: 970, Level: 12
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2006
Location: Bangalore, Karnataka, India.
Posts: 232
Thanks: 0
Thanked 1 Time in 1 Post
Default grid view

Hello to All
please solve my problen soon
i am using following code to get the checked value of text box.
but always it fires false:
1) gvcallerlist is name of grid
2) chkGridSelect is name of check box


protected void btnNext_Click(object sender, EventArgs e)
        {
           CheckBox chkSelected;
           foreach (GridViewRow gv in gvCallerList.Rows)
            {
                chkSelected = (CheckBox)gv.FindControl("chkGridSelect");

                if (chkSelected.Checked)
                {
                    //stNameGrid = ((Label) gv.FindControl("lblListNames").text;
                    Response.Redirect("default.aspx");
                }
            }
            if (ListNameGrid == "")
            {
                string Message = "<script language='javascript'>alert('Please Select one Calling Plan from the List.');</script>";
                Page.RegisterStartupScript("SelectRecord", Message);
                //ClientScript.RegisterStartupScript( "Message",Message);
            }


regards,
Munish bhatia

thanks......
__________________
thanks......
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #2 (permalink)  
Old May 25th, 2007, 08:26 AM
Registered User
 
Join Date: May 2007
Location: guntur, ap, India.
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to pavank
Default

you use...

bool ischecked=((CheckBox)gv.FindControl("chkGridSelect ")).Checked;

in place of chkSelected = (CheckBox)gv.FindControl("chkGridSelect");

  n write like

  if(ischecked)
{

}

try it ...

bye

pavan
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Grid view roopeshmkatlive.in ASP.NET 1.0 and 1.1 Professional 1 August 1st, 2008 02:03 PM
Help Grid View Drop Down List, view all jskinner123 ASP.NET 2.0 Basics 0 November 25th, 2007 06:25 PM
grid view komalpriya .NET Framework 2.0 3 November 7th, 2007 10:34 AM
grid view MunishBhatia ASP.NET 2.0 Professional 2 June 5th, 2007 01:15 AM
calender with grid view chandrasekhar ASP.NET 2.0 Professional 1 April 13th, 2006 02:20 PM



All times are GMT -4. The time now is 04:47 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
© 2008 Wiley Publishing, Inc