Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Access Drive Mapped to a Network Share

Reply
Thread Tools

Access Drive Mapped to a Network Share

 
 
Jerry C
Guest
Posts: n/a
 
      04-23-2008
I am trying to accesss a Mapped Drive from my asp.net code running on IIS 6.0.

I am using a FileUpload control and fileUpload.SaveAs() to save the file to
the server. I want to save the file to a mapped drive that is mapped to a
share on the network. When I save to "C:\temp\myFile.txt it works but when I
save to Z:\temp\myFile.txt is will not work. I also want to copy, delete and
move these files.
I have found some pages on the net that mention this but none of the fixes
work.

Any help.

Thank you
--
Jerry
 
Reply With Quote
 
 
 
 
Alexey Smirnov
Guest
Posts: n/a
 
      04-23-2008
On Apr 23, 11:14*pm, Jerry C <jerr...@nospam.nospam> wrote:
> I am trying to accesss a Mapped Drive from my asp.net code running on *IIS 6.0.
>
> I am *using a FileUpload control and fileUpload.SaveAs() to save the file to
> the server. I want to save the file to a mapped drive that is mapped to a
> share on the network. When I save to "C:\temp\myFile.txt it works but when I
> save to Z:\temp\myFile.txt is will not work. I also want to copy, delete and
> move these files.
> I have found some pages on the net that mention this but none of the fixes
> work.
>
> Any help.
>
> Thank you
> --
> Jerry


http://groups.google.com/group/micro...3ed675b1609854
 
Reply With Quote
 
 
 
 
Steven Cheng [MSFT]
Guest
Posts: n/a
 
      04-24-2008
Hi Jerry,

As for the mapped share drive problem, it is likely caused by the mapped
drive is not visible to your ASP.NET application. Because the mapped drive
is created under another interactive logon user while the ASP.NET
application runs under a dedicated process account.

Alexey has mentioned a thread which suggest that you use win32 api to
programmtically create the share drive in ASP.NET application(under the
ASP.NET process account) before you use it. In addition this, you can also
consider using Process Class to invoke "cmd.exe" and use "net use" command
to create the share.

#Net Use Command
http://www.cezeo.com/tips-and-tricks/net-use-command/

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead


Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
.

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.


--------------------
>From: =?Utf-8?B?SmVycnkgQw==?= <>
>Subject: Access Drive Mapped to a Network Share
>Date: Wed, 23 Apr 2008 14:14:00 -0700
>
>I am trying to accesss a Mapped Drive from my asp.net code running on IIS

6.0.
>
>I am using a FileUpload control and fileUpload.SaveAs() to save the file

to
>the server. I want to save the file to a mapped drive that is mapped to a
>share on the network. When I save to "C:\temp\myFile.txt it works but when

I
>save to Z:\temp\myFile.txt is will not work. I also want to copy, delete

and
>move these files.
>I have found some pages on the net that mention this but none of the fixes
>work.
>
>Any help.
>
>Thank you
>--
>Jerry
>


 
Reply With Quote
 
George Ter-Saakov
Guest
Posts: n/a
 
      04-24-2008
Cool, I was just about to repost the code then checked the link and saw
it.....
Google rocks


George.




"Alexey Smirnov" <> wrote in message
news:5e9edb74-1451-4ee4-902b-...
On Apr 23, 11:14 pm, Jerry C <jerr...@nospam.nospam> wrote:
> I am trying to accesss a Mapped Drive from my asp.net code running on IIS
> 6.0.
>
> I am using a FileUpload control and fileUpload.SaveAs() to save the file
> to
> the server. I want to save the file to a mapped drive that is mapped to a
> share on the network. When I save to "C:\temp\myFile.txt it works but when
> I
> save to Z:\temp\myFile.txt is will not work. I also want to copy, delete
> and
> move these files.
> I have found some pages on the net that mention this but none of the fixes
> work.
>
> Any help.
>
> Thank you
> --
> Jerry


http://groups.google.com/group/micro...3ed675b1609854


 
Reply With Quote
 
Jerry C
Guest
Posts: n/a
 
      04-24-2008
Alexey, Steven

Thank you very good information.


--
Jerry


"Steven Cheng [MSFT]" wrote:

> Hi Jerry,
>
> As for the mapped share drive problem, it is likely caused by the mapped
> drive is not visible to your ASP.NET application. Because the mapped drive
> is created under another interactive logon user while the ASP.NET
> application runs under a dedicated process account.
>
> Alexey has mentioned a thread which suggest that you use win32 api to
> programmtically create the share drive in ASP.NET application(under the
> ASP.NET process account) before you use it. In addition this, you can also
> consider using Process Class to invoke "cmd.exe" and use "net use" command
> to create the share.
>
> #Net Use Command
> http://www.cezeo.com/tips-and-tricks/net-use-command/
>
> Sincerely,
>
> Steven Cheng
>
> Microsoft MSDN Online Support Lead
>
>
> Delighting our customers is our #1 priority. We welcome your comments and
> suggestions about how we can improve the support we provide to you. Please
> feel free to let my manager know what you think of the level of service
> provided. You can send feedback directly to my manager at:
> .
>
> ==================================================
> Get notification to my posts through email? Please refer to
> http://msdn.microsoft.com/subscripti...ult.aspx#notif
> ications.
>
> Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
> where an initial response from the community or a Microsoft Support
> Engineer within 1 business day is acceptable. Please note that each follow
> up response may take approximately 2 business days as the support
> professional working with you may need further investigation to reach the
> most efficient resolution. The offering is not appropriate for situations
> that require urgent, real-time or phone-based interactions or complex
> project analysis and dump analysis issues. Issues of this nature are best
> handled working with a dedicated Microsoft Support Engineer by contacting
> Microsoft Customer Support Services (CSS) at
> http://msdn.microsoft.com/subscripti...t/default.aspx.
> ==================================================
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
>
> --------------------
> >From: =?Utf-8?B?SmVycnkgQw==?= <>
> >Subject: Access Drive Mapped to a Network Share
> >Date: Wed, 23 Apr 2008 14:14:00 -0700
> >
> >I am trying to accesss a Mapped Drive from my asp.net code running on IIS

> 6.0.
> >
> >I am using a FileUpload control and fileUpload.SaveAs() to save the file

> to
> >the server. I want to save the file to a mapped drive that is mapped to a
> >share on the network. When I save to "C:\temp\myFile.txt it works but when

> I
> >save to Z:\temp\myFile.txt is will not work. I also want to copy, delete

> and
> >move these files.
> >I have found some pages on the net that mention this but none of the fixes
> >work.
> >
> >Any help.
> >
> >Thank you
> >--
> >Jerry
> >

>
>

 
Reply With Quote
 
Alexey Smirnov
Guest
Posts: n/a
 
      04-24-2008
On Apr 24, 3:08*pm, "George Ter-Saakov" <gt-...@cardone.com> wrote:
> Google rocks
>


Indeed
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Share-Point-2010 ,Share-Point -2010 Training , Share-point-2010Hyderabad , Share-point-2010 Institute Saraswati lakki ASP .Net 0 01-06-2012 06:39 AM
Is there any module to map a network drive and remove a mapped network drive in perl king Perl Misc 1 10-22-2007 05:25 PM
difficulty to access a mapped network drive =?Utf-8?B?UGl5dXNoIFRyaXZlZGk=?= ASP .Net 1 11-03-2006 09:09 PM
Access Mapped Drive using Authenticated Access Marc ASP .Net Web Services 0 08-08-2006 03:21 PM
Mapped drive over WiFi network =?Utf-8?B?Q2hhbWJlcnM=?= Wireless Networking 2 12-04-2004 04:35 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57