• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1660
  • Last Modified:

Issue with ClientScript.RegisterClientScriptBlock

I have an application that I need to call a new window to open up a report.  Here is my full line statement:  ClientScript.RegisterClientScriptBlock(Me.GetType, "newwindow", "<script language=javascript>window.open('" & QueryString & "', 'NewWindow')</script>")

The problem I'm having is the new screen doesn't open up.  It just runs through the code and stays on the same page with opening a new page for the report.  The other thing is that I have the same line of code in another application and it works correctly.  The only difference that I can find is that the application that doesn't work is using a tab control from AJAX.  Could this be my problem?  Thanks for the help.
0
aot-johnstown
Asked:
aot-johnstown
1 Solution
 
Bob LearnedCommented:
RegisterClientScriptBlock doesn't execute the Javascript function, it adds the function to the page so that you can call it.  This is usually accomplished by adding an attribute to an HTML element.

Bob
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now