Solved

Call javascript function from vb.net code behind in asp.net 2.0 page

Posted on 2007-11-21
3
13,381 Views
Last Modified: 2013-11-26
Hello Experts,
From the code behind in 1 page, I need to open another aspx file in a modal window.  

Thanks

Howard
0
Comment
Question by:katzhoward
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 16

Accepted Solution

by:
SQL_SERVER_DBA earned 250 total points
ID: 20329060
function OpenAnother()
{
window.showModelessDialog( "RequestForm.aspx");
}
0
 
LVL 12

Expert Comment

by:needo_jee
ID: 20329180
in code behind use

Response.Write("<script language='Javascript'> window.open('youraspForm.aspx.','name',
'height=255,width=250,toolbar=no,directories=no,status=no,
menubar=no,scrollbars=no,resizable=no ,modal=yes');
</script>")
0
 
LVL 12

Assisted Solution

by:needo_jee
needo_jee earned 250 total points
ID: 20329286
I just tried in C#

string URL = "<script language='Javascript'> window.open('" + ResolveUrl("empDateTest.aspx") + "','name','height=255,width=250,toolbar=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no ,modal=yes');</script>";

        Response.Write(URL);

Thanks
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question