Not sure where this is breaking down, code is designed for backing up a USB to user’s home folder on the network drive. If the path is found, then a message "ok to backup" is displayed. I'm on the network and the path is valid however it always displays "Please connect to network or VPN". There is more to this code yet to be completed but I wanted to test this as I go trying to eliminate problems while building.
I'm still very new at this but having a blast!!!
public partial class Form1 : Form
private void Backup_button_Click(object sender, EventArgs e)
//Display message while checking access to home folder
Resultlabel.Text = ("Checking for access to John Doe's home folder");
//Short pause for message to be read
DateTime Tthen = DateTime.Now;
} while (Tthen.AddSeconds(3) > DateTime.Now);
//checking for network access
string strFullPath = "@\\SERVERNAME\\HOME\\jdoe";
Resultlabel.Text = ("Ok to backup files");
// backup process will be placed here copying all files to users network folder
Resultlabel.Text = ("Please connect to network or VPN");
// process to close application will go here