get user enter value from prompt window asp.net

Discussion in 'ASP .Net' started by ambersaria420@yahoo.com, Dec 17, 2004.

  1. Guest

    I need to prompt the user to enter ID. I can open up prompt fine using
    javascript code below. However I am not sure how to get value that user
    entered in user prompt window. I have to check this value to see if it
    exists in the database.

    Private Sub btnID_Click(ByVal sender As System.Object, ByVal e As
    System.EventArgs) Handles btnID.Click
    Dim strPop As String
    strPop = "<script language='javascript'>" & vbCrLf & "var temp
    = window.prompt('Enter ID:','');window.returnValue = temp;" & vbCrLf &
    "</script>" & vbCrLf
    Page.RegisterStartupScript("Pop", strPop)
    End Sub

    Thanks a lot
     
    , Dec 17, 2004
    #1
    1. Advertising

  2. hi..
    try with query string

    raj

    "" wrote:

    > I need to prompt the user to enter ID. I can open up prompt fine using
    > javascript code below. However I am not sure how to get value that user
    > entered in user prompt window. I have to check this value to see if it
    > exists in the database.
    >
    > Private Sub btnID_Click(ByVal sender As System.Object, ByVal e As
    > System.EventArgs) Handles btnID.Click
    > Dim strPop As String
    > strPop = "<script language='javascript'>" & vbCrLf & "var temp
    > = window.prompt('Enter ID:','');window.returnValue = temp;" & vbCrLf &
    > "</script>" & vbCrLf
    > Page.RegisterStartupScript("Pop", strPop)
    > End Sub
    >
    > Thanks a lot
    >
    >
     
    =?Utf-8?B?cmFqYW1hbmlja2Ft?=, Dec 17, 2004
    #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. Replies:
    2
    Views:
    4,928
    Alex Homer
    Dec 17, 2004
  2. Sunfire
    Replies:
    2
    Views:
    1,073
    Sunfire
    Nov 6, 2007
  3. gaurav kashyap
    Replies:
    2
    Views:
    634
    gaurav kashyap
    Oct 30, 2008
  4. Tom Jenkins
    Replies:
    10
    Views:
    195
    Thomas 'PointedEars' Lahn
    Oct 10, 2004
  5. HopfZ
    Replies:
    0
    Views:
    597
    HopfZ
    Aug 28, 2006
Loading...

Share This Page