How to get active row??

Discussion in 'ASP .Net Datagrid Control' started by JLuv, Jul 13, 2006.

  1. JLuv

    JLuv Guest

    I have a TemplateColumn in my DataGrid that consists of links. When the
    links are clicked a javascript calendar is opened that returns a
    selected date to a HiddenField. What I'm trying to do is take the row
    in which the calendar was chosen and change the date inside of the
    datagrid. (if that makes sense)
    I know how to use "this.myGrid.Items[row].Cells[column]" to access
    datagrid info, but i don't know how i would be able to tell my web app
    which row was clicked.
    I'm using C# ASP.NET, btw.
    Any help? If this isn't enough info, plz let me know.
    JLuv, Jul 13, 2006
    #1
    1. Advertising

  2. JLuv

    JLuv Guest

    Ok, maybe a better way to put this...I want to know which row the link
    was clicked on.
    Then from there, I would know the row/column combination to use so that
    I can change the correct date.

    JLuv wrote:
    > I have a TemplateColumn in my DataGrid that consists of links. When the
    > links are clicked a javascript calendar is opened that returns a
    > selected date to a HiddenField. What I'm trying to do is take the row
    > in which the calendar was chosen and change the date inside of the
    > datagrid. (if that makes sense)
    > I know how to use "this.myGrid.Items[row].Cells[column]" to access
    > datagrid info, but i don't know how i would be able to tell my web app
    > which row was clicked.
    > I'm using C# ASP.NET, btw.
    > Any help? If this isn't enough info, plz let me know.
    JLuv, Jul 13, 2006
    #2
    1. Advertising

  3. JLuv

    JLuv Guest

    ok, i found a solution. i ended up using an EditCommandColumn that i
    found in the following article.
    http://samples.gotdotnet.com/quickstart/aspplus/doc/webdataaccess.aspx

    JLuv wrote:
    > Ok, maybe a better way to put this...I want to know which row the link
    > was clicked on.
    > Then from there, I would know the row/column combination to use so that
    > I can change the correct date.
    >
    > JLuv wrote:
    > > I have a TemplateColumn in my DataGrid that consists of links. When the
    > > links are clicked a javascript calendar is opened that returns a
    > > selected date to a HiddenField. What I'm trying to do is take the row
    > > in which the calendar was chosen and change the date inside of the
    > > datagrid. (if that makes sense)
    > > I know how to use "this.myGrid.Items[row].Cells[column]" to access
    > > datagrid info, but i don't know how i would be able to tell my web app
    > > which row was clicked.
    > > I'm using C# ASP.NET, btw.
    > > Any help? If this isn't enough info, plz let me know.
    JLuv, Jul 13, 2006
    #3
  4. JLuv

    Guest

    JLuv,

    Try using Datagrid1_itemCreated

    --Venkat
    JLuv wrote:
    > ok, i found a solution. i ended up using an EditCommandColumn that i
    > found in the following article.
    > http://samples.gotdotnet.com/quickstart/aspplus/doc/webdataaccess.aspx
    >
    > JLuv wrote:
    > > Ok, maybe a better way to put this...I want to know which row the link
    > > was clicked on.
    > > Then from there, I would know the row/column combination to use so that
    > > I can change the correct date.
    > >
    > > JLuv wrote:
    > > > I have a TemplateColumn in my DataGrid that consists of links. When the
    > > > links are clicked a javascript calendar is opened that returns a
    > > > selected date to a HiddenField. What I'm trying to do is take the row
    > > > in which the calendar was chosen and change the date inside of the
    > > > datagrid. (if that makes sense)
    > > > I know how to use "this.myGrid.Items[row].Cells[column]" to access
    > > > datagrid info, but i don't know how i would be able to tell my web app
    > > > which row was clicked.
    > > > I'm using C# ASP.NET, btw.
    > > > Any help? If this isn't enough info, plz let me know.
    , Jul 14, 2006
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Dan Sikorsky
    Replies:
    2
    Views:
    11,470
    SiliconViper
    Apr 30, 2009
  2. Replies:
    5
    Views:
    656
  3. sauce
    Replies:
    0
    Views:
    229
    sauce
    Apr 12, 2005
  4. D
    Replies:
    0
    Views:
    203
  5. Replies:
    1
    Views:
    133
Loading...

Share This Page