As SA said, just try to create the file. Below is a simple routine that returns true if a file can be created in the specified directory.
private bool CheckDirectoryWriteAccess(string dirPath)
{
bool result = false;
if (System.IO.Directory.Exists(dirPath))
{
try
{
string filename = System.DateTime.Now.ToString("yyyymmdd_hhmmss_fff") + ".tmp";
System.IO.File.Create(dirPath + filename).Close();
if (System.IO.File.Exists(dirPath + filename))
{
result = true;
}
System.IO.File.Delete(dirPath + filename);
}
catch (UnauthorizedAccessException ex)
{
}
catch (Exception ex)
{
}
}
return result;
}