473,385 Members | 1,536 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

C# windows services cannot access network files and folders

I have got a windows service installed through installutil in C#.I have change the login settings from localsystems todomain/user. The user can access the network resources with noproblems but if the windows services can't. Directory.Existreturns false, but true if I use a normal C# windows app.
--------------------------------
From: Razor Works

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

<Id>De0TDTLgHE+WVdZqXdoEBg==</Id>
Jul 21 '05 #1
1 2886
Do you access network files by using mapped drives like
'N:\somefolder\myfile.txt'? If so, change to the UNC naming convention
'\\myserver\myshare\somefolder\myfile.txt'. Keep in mind that logon scripts
are not executed for windows services and even manually assigned drive
letters are not accessible in the context of a windows service.

Hope that helps,
Guido

"Razor Works via .NET 247" wrote:
I have got a windows service installed through installutil in C#. I have change the login settings from localsystems to domain/user. The user can access the network resources with no problems but if the windows services can't. Directory.Exist returns false, but true if I use a normal C# windows app.
--------------------------------
From: Razor Works

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

<Id>De0TDTLgHE+WVdZqXdoEBg==</Id>

Jul 21 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Mullin Yu | last post by:
if i put the same code at the windows application or console, i can logon to the computer. but, if i put the same code at the windows service and start it, i still can't logon to the machine. ...
8
by: Pete Wittig | last post by:
Hello, I am wondering if it is possible to create a networked application with C# that is seen as a windows user. For example, if Bob logged onto windows and then started the application, any...
2
by: Joseph Geretz | last post by:
I'm having a credentialing problem in my web application. Actually, I don't think this is an IIS security issue, since I'm able to access the page I'm requesting. However, the executing page itself...
1
by: Razor Works via .NET 247 | last post by:
I have got a windows service installed through installutil in C#.I have change the login settings from localsystems todomain/user. The user can access the network resources with noproblems but if the...
17
by: Jon B | last post by:
Hi All! I have a ASP.NET 2.0 site that works on the Windows 2000 Server. However, when I tried to view this site on my local Windows XP machine, I get "Server Unavailable". If I switch the...
10
by: dermot | last post by:
I have wrriten a small windows service application in visual studio ..net 2003 which listens for incoming FTP files. These files would overwrite over time due to duplicate file names. However any...
2
by: Walt | last post by:
I need to access a network folder with read/write permissions from a windows service application. I get an error "Access denied..." whenever I try to access a shared folder on the network. On...
4
by: sajid_yusuf | last post by:
Hi I am trying to develop a Windows service in VB.NET which has timer enabled and keeps checking a folder (or group of folders) for any new file or changed files. As soon as it detects any new...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.