on click of a link button should first save the data and then open a new browser

Discussion in 'ASP .Net' started by Mathew George, Jul 1, 2003.

  1. Hi,

    A page consists of a link button. Clicking this link button should first
    save data in the database.
    If the data is saved correctly then it should open a new window.

    I have coded for the link button as

    Private Sub Button1_Click
    (ByVal sender As System.Object, ByVal e As System.EventArgs)
    Handles Button1.Click
    ' perform database save here
    Response.Write("<script>window.open();</script>")
    End Sub


    Can anyone suggest which is the best method in terms of reliability and
    performance.

    Regards,
    Mathew
     
    Mathew George, Jul 1, 2003
    #1
    1. Advertising

  2. Mathew George

    soni Guest

    Hi mathew..
    well it looks fine.. as long as u r not doing any major DB work in the
    button _onclick event. ( this should be done in ur middle tier)
    the rest looks fine unless someone differs ..
     
    soni, Jul 2, 2003
    #2
    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. shil
    Replies:
    6
    Views:
    11,366
  2. Mufasa
    Replies:
    7
    Views:
    418
    Alexey Smirnov
    Sep 4, 2007
  3. Mathew George
    Replies:
    0
    Views:
    160
    Mathew George
    Jul 1, 2003
  4. Mathew George
    Replies:
    0
    Views:
    175
    Mathew George
    Jul 1, 2003
  5. Replies:
    0
    Views:
    295
Loading...

Share This Page