Hi, i have written an app that needs to connect to a server that has access rights associated with it. If i am logged on as a certain person who has access privaleges there is not a problem. In certain circumstances the computer running my app has not network connection to a domain. I have programmed access to the domain but the server i need to access data on in the domain is user and password protected. If i use the following code i cannot access the file.

using (StreamReader sr = new StreamReader("\\\\Ukptserver03\\Archive\\Users.Dat"))
{
String line;
while ((line = sr.ReadLine()) != null)
{
.....etc

Are there any other parameters i need to pass to the streamreader or do i need to set something else up.

Thanks.