Passing values from .aspx to .aspx.vb

earvin_paul

Newcomer
Joined
Apr 5, 2005
Messages
2
Hello! i have a problem.. i try to open a modal window using window.showmodaldialog(URL, Argument, Features). I have retrieved the values i passed to the modal window through the Argument from window.dialogArguments in the html code(.aspx). the problem is I cannot pass this value to my codebehind(.aspx.vb) in pageload. how do i pass a value from my .aspx code to .aspx.vb code at page load? :o
 
Use the Arguument parameter to pass in a reference to your parent window. Use the URL paramter to pass in your values you want your code behind to process. like

"test.aspx?param1=value1"

Btw, showmodaldialog only works in IE
 
kahlua001 said:
Use the Arguument parameter to pass in a reference to your parent window. Use the URL paramter to pass in your values you want your code behind to process. like

"test.aspx?param1=value1"

Btw, showmodaldialog only works in IE

Thanks kahlua001! but please check if my syntax is correct...

so im gonna call my modal using

dim myObject as string = "This is my Name"
response.write(<script>window.showModalDialog("Page.htm?input=myObject", null, "dialogHeight:450px; dialogwidth:680px;");</script>)

and in my modal page im going to get the value that i passed (which is the variable "myObject" in the parameter "input") by

Dim strQuery As String = String.Empty
If Not Request.QueryString("input") = Nothing Then
strQuery = Request.QueryString("input")
End If

it's not working... :(
 
Back
Top