DHTML Methods in ASP

  • Thread starter Thread starter Bob T
  • Start date Start date
B

Bob T

Hi All,

I am a bit of a newbie but have a reasonable grasp of using ASP.net code.

One thing I have wanted to find our for sometime is if there is a way to
invoke DHTML methods from or after running an ASP.net event.

For example/
I can open a modal dialog using the DHTML method
<input type = "button" onclick = "window.showmodaldialog("webpage.aspx")">

When I finish on this modal dialog, I can close it with
<input type = "button" onclick = "window.close()">

Is there a way run some ASP code and invoke these or other DHTML methods, or
finish the ASP code and then send a command to the browser to execute one of
these DHTML methods. The reason I want do this is I want to store some data
on either the main page of the modaldialog before opening or closing the
modal dialog.

I have been able to functionally do what I need with
Response.Redirect("webpage.aspx")
but I prefer the look of a dialog box for this function instead of going to
a new page.

Thanks in advance.

Bob T
 
i cant say much about dhtml but i know you can attach javascript to a
web control

eg
TextBox1.Attributes("onclick")="javascript:alert('Hello! you just
clicked me!');"
 
Back
Top