How to call javascript when click update command(it Edit command c

Discussion in 'ASP .Net Web Controls' started by prakash, Apr 8, 2005.

  1. prakash

    prakash Guest

    hi

    can any one help out....

    It is possible to call the javascript..when i click update command in
    datagrid.
    (in Edit Command Column) For validation.

    eg:- like button.Attribute.Add("onclick","function name()")

    I am using EDIT Commnad Column.


    Another query...

    my required field validator is working in my local system,when i click
    the update command in datagrid. But it not workin in the main server machine.
    so i gone 1 query.

    Thanks In advance

    Regards
    Prakash.S
     
    prakash, Apr 8, 2005
    #1
    1. Advertising

  2. Hi Prakash,

    Yes it is possible to add a JavaScript onClick attribute exactly like you
    mentioned. Another way thought if you want to use the built in .NET
    validators is to create template columns in your DataGrid and just handle the
    validator controls the same as you would on a regular page.

    Cheers,
    Steve Goodyear
    Vancouver, Canada
     
    Steve Goodyear, Apr 8, 2005
    #2
    1. Advertising

  3. prakash

    prakash Guest

    RE: How to call javascript when click update command(it Edit comma

    hi steve,

    how can i add javascript onclick attribute to update command(i am using Edit
    Command Colume).can u give sample code plz .it would be helpful for me.

    if we have button then it is easy by specifiying it id(name) we can add the
    attributes to it.
    but i am using Edit command column,how can i achive it ,how can i specify
    the button name for the update command.

    Thanks in advance

    Regards
    Prakash.S
     
    prakash, Apr 11, 2005
    #3
    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. San Diego Guy
    Replies:
    0
    Views:
    582
    San Diego Guy
    Aug 7, 2003
  2. Smash
    Replies:
    3
    Views:
    391
    Elton Wang
    Feb 21, 2005
  3. Frank Kurka
    Replies:
    8
    Views:
    343
  4. pepsi
    Replies:
    0
    Views:
    506
    pepsi
    Apr 11, 2005
  5. Jaime Stuardo

    GridView control enters edit mode when I click Edit link twice

    Jaime Stuardo, Apr 7, 2006, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    451
    Jaime Stuardo
    Apr 7, 2006
Loading...

Share This Page