Uploading file to local host

  • Thread starter Thread starter jackson
  • Start date Start date
J

jackson

Hi all,
Im having problem when uploading file to localhost.
but I can upload to drive c:
any idea

thanks
 
Hi,

what do you mean by localhost. That's a virtual directory, mapping to some
real one, e.g. http://localhost commonly maps to C:\Inetpub\wwwroot etc.
Just make sure wherever you are uploading, ASP .NET has relevant permission
to do so.

Let me know if you need anything else.

Thanks

Joyjit
 
Hello there,
Yes what I mean by localhost is my virtual server which
is located at C:\Inetpub\wwwroot etc. But once I upload
my file to the particular path its always error.
any idea?
 
But once I upload my file to the particular path its always error.

There's very little point posting on a software support newsgroup saying
that you're getting an error if you don't actually tell the group what that
error is...

E.g.

I wrote a method in a C# class yesterday but it kept giving me an error. Can
you tell me what that means and how I can fix it?
 
It's probably a security issue.
The ASPNET user account must have write permission to the folder.
Or you can use impersonation to have ASP.NET run under a different user
account that does have the necessary permission.

For example, you can add a line similar to this to your web.config file:
<identity impersonate="true" userName="domain\MyUserName">
password="password"/>

Here's more info on impersonation:
http://msdn.microsoft.com/library/d...-us/cpguide/html/cpconaspnetimpersonation.asp

And here's another article that may help:
http://SteveOrr.net/articles/EasyUploads.aspx
 
Hi there,

this is the error message:
The statement has been terminated. String or binary data
would be truncated
I save it to the
C:\Inetpub\wwwroo\myServer\uploadFolder\xxx.txt
 
Back
Top