getting URL form config file

Homi69

New Member
I am tring to store the URL in the confoguartion file, but it does not work when I retrive the URL from the fileBelow is my codeIn web.config, I have\[code\] <add key="URL" value="http://stackoverflow.com/NG/Viewer/ViewerSummary.aspx"/>\[/code\]in my aspx.cs page, I have th following code\[code\] string url = ConfigurationManager.AppSettings["URL"];string strScript = "window.open(url?QueryID=" + QueryId + "', '_blank','height=650, center:yes, width=800, status=no, resizable= yes, menubar=no, toolbar=no, location=yes, scrollbars=yes, status=no');"; ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "strScript", strScript, true);\[/code\]the window does not open if I write the above code, but window opens if I do this below code.\[code\]string strScript = "window.open('/NG/Viewer/ViewerSummary.aspx?QueryID=" + QueryId + "', '_blank','height=650, center:yes, width=800, status=no, resizable= yes, menubar=no, toolbar=no, location=yes, scrollbars=yes, status=no');"; ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "strScript", strScript, true);\[/code\]how can I open the window bu putting the value in the config file.any help is appreciated.Thanks.
 
Back
Top