Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Enable options according to button click [modified]

Enable options according to button click [modified]

Scheduled Pinned Locked Moved ASP.NET
helpcssdatabase
10 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    Tash18
    wrote on last edited by
    #1

    Hi im actually working on a project. Actually its about storing and retrieving student details from the data base. I hav totally designed 3 webforms. 1st webform has a login form 2nd webform has 3 buttons in it 3rd webform has the grid view which displays the student records frm DB Now heres the problem actually when i click button1 in my 2nd webform it must disable the edit and delete option of my grid view in the 3rd webform and wen i click button2 in 2nd webform it must enable the edit and delete option in my gridview in the 3rd webform. the edit and delete are link buttons. Can anyone plzzz help me its bit urgent... Thashif

    modified on Thursday, June 18, 2009 7:08 AM

    H 2 Replies Last reply
    0
    • T Tash18

      Hi im actually working on a project. Actually its about storing and retrieving student details from the data base. I hav totally designed 3 webforms. 1st webform has a login form 2nd webform has 3 buttons in it 3rd webform has the grid view which displays the student records frm DB Now heres the problem actually when i click button1 in my 2nd webform it must disable the edit and delete option of my grid view in the 3rd webform and wen i click button2 in 2nd webform it must enable the edit and delete option in my gridview in the 3rd webform. the edit and delete are link buttons. Can anyone plzzz help me its bit urgent... Thashif

      modified on Thursday, June 18, 2009 7:08 AM

      H Offline
      H Offline
      himanshu2561
      wrote on last edited by
      #2

      Are they websites or webforms?? :confused:

      himanshu

      T 1 Reply Last reply
      0
      • H himanshu2561

        Are they websites or webforms?? :confused:

        himanshu

        T Offline
        T Offline
        Tash18
        wrote on last edited by
        #3

        Dey r all asp websites..

        A 1 Reply Last reply
        0
        • T Tash18

          Dey r all asp websites..

          A Offline
          A Offline
          Amol 111
          wrote on last edited by
          #4

          WEBSITES are u sure or they are like page1.aspx,page2.aspx,page3.aspx.

          T 1 Reply Last reply
          0
          • A Amol 111

            WEBSITES are u sure or they are like page1.aspx,page2.aspx,page3.aspx.

            T Offline
            T Offline
            Tash18
            wrote on last edited by
            #5

            im sorry its actually de way u said page1.aspx,page2.aspx,page3.aspx

            H 1 Reply Last reply
            0
            • T Tash18

              im sorry its actually de way u said page1.aspx,page2.aspx,page3.aspx

              H Offline
              H Offline
              himanshu2561
              wrote on last edited by
              #6

              Man that are webforms not websites

              himanshu

              T 1 Reply Last reply
              0
              • H himanshu2561

                Man that are webforms not websites

                himanshu

                T Offline
                T Offline
                Tash18
                wrote on last edited by
                #7

                Im so sorry regarding dat... would u plzzzz help me

                1 Reply Last reply
                0
                • T Tash18

                  Hi im actually working on a project. Actually its about storing and retrieving student details from the data base. I hav totally designed 3 webforms. 1st webform has a login form 2nd webform has 3 buttons in it 3rd webform has the grid view which displays the student records frm DB Now heres the problem actually when i click button1 in my 2nd webform it must disable the edit and delete option of my grid view in the 3rd webform and wen i click button2 in 2nd webform it must enable the edit and delete option in my gridview in the 3rd webform. the edit and delete are link buttons. Can anyone plzzz help me its bit urgent... Thashif

                  modified on Thursday, June 18, 2009 7:08 AM

                  H Offline
                  H Offline
                  himanshu2561
                  wrote on last edited by
                  #8

                  Can't you keep buttons and gridview on same form?? If not then do something like Session["click"]="button1" // on the click on Button1 Session["click"]="button2" //on the click on Button2 In the page where you have gridview check.. If(Session["click"].Tostring()=="button1") //Disable your gridview link buttons else //Enable your gridview link buttons

                  himanshu

                  T 1 Reply Last reply
                  0
                  • H himanshu2561

                    Can't you keep buttons and gridview on same form?? If not then do something like Session["click"]="button1" // on the click on Button1 Session["click"]="button2" //on the click on Button2 In the page where you have gridview check.. If(Session["click"].Tostring()=="button1") //Disable your gridview link buttons else //Enable your gridview link buttons

                    himanshu

                    T Offline
                    T Offline
                    Tash18
                    wrote on last edited by
                    #9

                    thanx... wel got another code too whch worked out... check dis out... protected void Button1_Click(object sender, EventArgs e) { Response.Redirect("http://Gridview.aspx?ctl=1"); } protected void Button2_Click(object sender, EventArgs e) { Response.Redirect("http://Gridview.aspx?ctl=2"); } Now in de page wer de grid is present Int32 str = Convert.ToInt32(Request.QueryString["Ctl"]); if (str == 1) { //enable de edit button } else { //enable de delete button } Thanx a lot....

                    H 1 Reply Last reply
                    0
                    • T Tash18

                      thanx... wel got another code too whch worked out... check dis out... protected void Button1_Click(object sender, EventArgs e) { Response.Redirect("http://Gridview.aspx?ctl=1"); } protected void Button2_Click(object sender, EventArgs e) { Response.Redirect("http://Gridview.aspx?ctl=2"); } Now in de page wer de grid is present Int32 str = Convert.ToInt32(Request.QueryString["Ctl"]); if (str == 1) { //enable de edit button } else { //enable de delete button } Thanx a lot....

                      H Offline
                      H Offline
                      himanshu2561
                      wrote on last edited by
                      #10

                      yup same thing.you can either use session or query string

                      himanshu

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups