Solved

opening url in new browser...but url is along a different directory structure

Posted on 2009-05-11
1
188 Views
Last Modified: 2012-05-06
I have some code I can use to open a url in a different browser window

Response.Write("<SCRIPT language=javascript>var w=window.open('Report.aspx');</SCRIPT>");

But the aspx "report.aspx" is actually along a different directory path. Its a couple of levels lower and one level up the tree.

('~/Utils/Reports/Report.aspx');

but using that structure doesnt work in teh above example.

So anyone knwo HOw I can open the url with the diferent path like in teh above example.

I cant put in a static http: url because it changes depending on teh enviornment the app is installed in.
0
Comment
Question by:Prysson
1 Comment
 
LVL 12

Accepted Solution

by:
GuitarRich earned 500 total points
Comment Utility
try this
Response.Write("<SCRIPT language=javascript>var w=window.open('" + ResolveUrl("~/Utils/Reports/Report.aspx") + ');</SCRIPT>");

Open in new window

0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

This article describes a simple method to resize a control at runtime.  It includes ready-to-use source code and a complete sample demonstration application.  We'll also talk about C# Extension Methods. Introduction In one of my applications…
Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

743 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now