Solved

IIS Could not find a part of the path

Posted on 2015-01-08
5
722 Views
Last Modified: 2015-01-14
Calling this code from C# web app:
                            return File(path, "application/msexcel",trimmedPath);

Open in new window

If I run in Visual studio the command works and the file is downloaded.  If I run on the server I get this error
Could not find a part of the path 'r:\results\19262\19262-BA-T1\19262-BA-T1-19262-BA-T1-2_12_11_2014_32C_CST_8870.xlsx'.

Open in new window

If I copy that path into explorer it opens on the server
In IIS I have set Physical path credentials to my userID
0
Comment
Question by:Lab Guy
[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
  • 4
5 Comments
 
LVL 23

Expert Comment

by:Michael Fowler
ID: 40539151
I am assuming that r is a mapped network drive. Try using the network path instead eg \\server\....
0
 

Author Comment

by:Lab Guy
ID: 40540186
Tried that as well, get this error:
Access to the path '\\servername\rts\results\19262\19262-BA-T1\19262-BA-T1-19262-BA-T1-2_12_11_2014_32C_CST_8870.xlsx' is denied.

Open in new window

0
 

Author Comment

by:Lab Guy
ID: 40540265
With the UNC method, here is the Proc Mon info:Process Mon
0
 

Accepted Solution

by:
Lab Guy earned 0 total points
ID: 40541421
Resolved it.  Issue was that the process was running under the application pool user credentials. Switched it to the NETWORK SERVICE user and it worked.
0
 

Author Closing Comment

by:Lab Guy
ID: 40548535
Figured it out with help from another source
0

Featured Post

Get Actionable Data from Your Monitoring Solution

Your communication platform is only as good as the relevance of the information you send. Ensure your alerts get to the right people every time with actionable responses. Create escalation rules that ensure everyone follows the process and nothing is left to chance.

Question has a verified solution.

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

Debug Tools to analyse IIS process: This article focus on taking memory dumps from IIS to determine which code is taking more time and to analyse which calls hangs/causes more CPU usage. To take dumps,download the following. Install1: To st…
If you are a web developer, you would be aware of the <iframe> tag in HTML. The <iframe> stands for inline frame and is used to embed another document within the current HTML document. The embedded document could be even another website.
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…

691 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