|
Rank: Advanced Member Groups: Member
Joined: 8/31/2008 Posts: 33
|
Hi,
I'm attempting to implement an AJAXUploader control and need the final resting place of the uploaded file to be a DFS share on my network. i.e. //DC/Files/CustomerFiles. When I set the property to this value I get the following error:
Failed to map the path '/DC/Files/CustomerFiles'
I was fiddling with this issue yesterday and also saw an error message that said the path needs to start with "~/directory name" and be relative to my root directory.
Thanks, CN
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,193
|
Hi,
TempFileLocation is for temp files, not final files. So you definitely do not want to set TempFileLocation to "//DC/Files/CustomerFiles", you can try to TempFileLocation to a different directory that is under your web application and set FinalFileLocation to "//DC/Files/CustomerFiles" instead.
When user uploads a file, the file is first transferred to TempFileLocation, it is then moved to FinalFileLocation. So the contents in TempFileLocation will not accumulate. You do not have to clean up that directory either.
Hope this helps.
Thanks
|
|
Rank: Advanced Member Groups: Member
Joined: 8/31/2008 Posts: 33
|
Thanks for the speedy reply. One more question:
When set the FileExplorer RootFolder property to "//dc/files/customerfiles" I receive the following erorr:
Failed to map the path '\dc\files\customerfiles'.
Thanks, Chris
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,193
|
Hi,
You can't really just point about everything to "//dc/files/customerfiles". :) Most ASP.NET controls works with files that are "within" the application because files that are outside of the application is not accessible by your users. Take FileExplorer as an example, if we were to allow you to point to "//dc/files/customerfiles", the user may get a path like "//dc/files/customerfiles/image1.gif". Such a path usually would not work in an Internet environment where users are not in the same network as your server ---- thus they would have no access to “//dc”.
For this very reason FileExplorer works with “application relative path”, which are paths that are within your application. To make a path within your application, you will want to go to IIS to configure it as a virtual path under your application. It’s a fairly simple procedure and there should be plenty of articles about this on the Internet.
Once you have set “//dc/files/customerfiles” as a virtual directory under your application, for example, as “customerfiles”, you should be able to set FileExplorers’ Root to “~/customerfiles”. FileExplorer will then work correctly.
Hope this helps.
Thanks
|
|
Rank: Advanced Member Groups: Member
Joined: 8/31/2008 Posts: 33
|
Thanks for the reply. I did set up a virtual directory and it worked fine but I wanted to confirm it was necessary since it adds complexity when the project is rolled out.
Thanks for the help.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,193
|
Yes. A virtual directory is necessary.
Please feel free to let us know if you have any more questions.
Thanks
|
|
Rank: Advanced Member Groups: Member
Joined: 8/31/2008 Posts: 33
|
I'm still struggling with this implementation. I configured the virtual directories and have that part of the implementation working but when I upload a file through the file explorer I get the following error:
EO.Web control 'ctl_mainContent_FileExplorer2_ctl00' error message: The callback on 'ctl_mainContent_FileExplorer2_ctl00' has failed because the server did not recognize this callback and processed it as regular request.
After I click OK several times to get past error dialog the page completes and displays the file explorer but does not display the most recently uploaded file. If I refresh the page the newly uploaded file will be displayed. I'm using an unmodified file explorer template from the 'Custom Layout - File Only' sample and on a web form that does use a master page in my app. The master page doesn't have any AJAX or JavaScript in it.
Thanks, Chris
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,193
|
Hi,
If you are only using FileExplorer, then you should not configure the uploader's FinalFileLocation. You only need to configure its TempFileLocation because the FinalFileLocation is automatically set by the FileExplorer.
We are not exactly sure what caused the problem for you. But can you try to run the "Custom Layout - File Only" directly from our sample project? Please let us know whether that works on your machine or not. Also, if you can put the page that demonstrates the problem online, we will be happy to take a look and see what's going on.
Thanks
|
|
Rank: Advanced Member Groups: Member
Joined: 8/31/2008 Posts: 33
|
OK, I ran your sample application and received the following error:
Server Error in '/EOWebDemo_Net20_CS' Application.
Configuration Error Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.
Source Error:
Line 25: ASP.NET to identify an incoming user. Line 26: --> Line 27: <authentication mode="Windows"/> Line 28: <!-- Line 29: The <customErrors> section enables configuration
Source File: C:\Program Files\Essential Objects\EO.Web Controls 2008\Net20\Samples\CS\demos\file explorer\features\custom layout - file only\web.config Line: 27
I verified the aplication has permission and is set for script and executables.
What am I doing wrong?
Thanks, Chris
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,193
|
Hi,
This is mostly caused by our application configuration error where our demo application is configured as a child directory but not a root application. We have setup an online meeting for you if you wish us to take a look of the problem. Please check your private message for the meeting link.
Thanks!
|
|
Rank: Advanced Member Groups: Member
Joined: 8/31/2008 Posts: 33
|
I rebuilt the page in a new web form by re-dragging the controls onto the form and copying my code behind into the new page and it seemed to do the trick. The control works now so I think we should chalk this one up to some kind of corruption in the designer generated code. I really appreciate your timely and professional responses.
- Chris
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,193
|
Not a problem. Please feel free to let us know if you run into any other problems!
|
|