Response.Redirect()


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2

Thread: Response.Redirect()

  1. #1
    michael Guest

    Response.Redirect()


    How do I open a webform in a new browser without navigating from the current
    webform?

    Private Sub DataGrid1_EditCommand(ByVal source As Object, ByVal e As System.Web.UI.WebControls.DataGridCommandEventArgs)
    Handles DataGrid1.EditCommand

    If e.CommandSource.Text = "Edit" Then
    Dim sID As String = "?SampleID=" & DataGrid1.Items(e.Item.DataSetIndex).Cells(2).Text

    'This will open it in the current browser
    Response.Redirect("Sample.aspx" & sID)

    'How do I open it in a NEW browser?

    End If

    Thanks
    Michael

  2. #2
    Jagdish Guest

    Re: Response.Redirect()



    Have you tried posting back to the current webform itself with a flag to
    indicate opening of a new webform. Check for that flag and then Use javascript
    'window.open()' method to open new browser with Sample.aspx URL .(use Onload
    event(clientside))




    "michael" <mmayfield_NOSPAM@houston.rr.com> wrote:
    >
    >How do I open a webform in a new browser without navigating from the current
    >webform?
    >
    >Private Sub DataGrid1_EditCommand(ByVal source As Object, ByVal e As System.Web.UI.WebControls.DataGridCommandEventArgs)
    >Handles DataGrid1.EditCommand
    >
    > If e.CommandSource.Text = "Edit" Then
    > Dim sID As String = "?SampleID=" & DataGrid1.Items(e.Item.DataSetIndex).Cells(2).Text
    >
    > 'This will open it in the current browser
    > Response.Redirect("Sample.aspx" & sID)
    >
    > 'How do I open it in a NEW browser?
    >
    > End If
    >
    >Thanks
    >Michael



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center