By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,341 Members | 1,619 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,341 IT Pros & Developers. It's quick & easy.

javascript to open a file from local settings temp folder

P: 40
Hi I used the following script in my aspx.cs page for opening a xml file in new window,

Expand|Select|Wrap|Line Numbers
  1. StringBuilder strScript = new StringBuilder();
  2.         strScript.Append("<script language='javascript' type='text/javascript'>");
  3.  
  4.        strScript.Append("window.open(belva_14_02_2009518.xml','access','left=0, top=0, toolbar=no,menubar=no,width=1000,height=8000,resizable=yes,scrollbars=yes');");
  5.         strScript.Append("</script>");

it works fine.. for the file being in application folder itself.
How to open a xml file from local settings temp folder and display in new window..

i tried giving 'C:\\Documents and Settings\\AS\\Local Settings\\Temp\\belva_14_02_2009518.xml' for the filename.. but it shows nothing.

Please reply asap.

Thanks in advance
Dec 2 '09 #1
Share this Question
Share on Google+
1 Reply


Dormilich
Expert Mod 5K+
P: 8,639
How to open a xml file from local settings temp folder and display in new window..
do you mean on the client or the server?

if itís on the client, you may have a chance with IE and very liberal security settings, on the server you can only access files somewhere in the serverís root directory
Dec 2 '09 #2

Post your reply

Sign in to post your reply or Sign up for a free account.