get user enter value from prompt window asp.net

A

ambersaria420

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
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,733
Messages
2,569,440
Members
44,832
Latest member
GlennSmall

Latest Threads

Top