# FileSystem.GetDirectory Exception

**URL:** <https://tech-community.robotics.abb.com/t/filesystem-getdirectory-exception/2260>\
**Category:** Developer Tools\
**Created:** [October 31, 2008, 2:07pm UTC](https://tech-community.robotics.abb.com/t/filesystem-getdirectory-exception/2260 "2008-10-31T14:07:08Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pedro](https://dub1.discourse-cdn.com/flex005/user_avatar/tech-community.robotics.abb.com/pedro/32/4340_2.png) [@Pedro](https://tech-community.robotics.abb.com/u/Pedro)\
**Post date:** [October 31, 2008, 2:07pm UTC](https://tech-community.robotics.abb.com/t/filesystem-getdirectory-exception/2260/1 "2008-10-31T14:07:08Z")

</div>

Essentially I’m trying to automate backup creation and retrieval for archiving using the PC SDK interface. I figured out how to create a backup on the controller, but I’m having trouble getting the directory on the controller containing the backup and copying to the computer running an application with the PC SDK. Here’s what I have ([VB.Net](http://VB.Net)):

With ABBController.FileSystem  
.RemoteDirectory = “(BACKUP)$”  
.LocalDirectory = “C:”  
If .DirectoryExists(“Remote\_Dir”) Then  
.GetDirectory(“Remote\_Dir”, “Local\_Dir”, True)  
End If  
End With

Running this snippet will generate a GenericControllerException with the message “Error accessing/creating file on the local file system.”. When I compare the directory/file structure of my local and remote directories, I find that the HOME directory created on my PC contains none of the files found in the HOME directory on the controller’s backup. Everything else appears to have copied correctly. Is this by design? Is there another way to retrieve the entire backup?

Thanks,  
Pedro

---

<div class="post-metadata">

**Author:** ![carlosmtz2000](https://avatars.discourse-cdn.com/v4/letter/c/e79b87/32.png) [@carlosmtz2000](https://tech-community.robotics.abb.com/u/carlosmtz2000)\
**Post date:** [November 3, 2008, 4:39pm UTC](https://tech-community.robotics.abb.com/t/filesystem-getdirectory-exception/2260/2 "2008-11-03T16:39:15Z")

</div>

Hola Pedro,

When you said that you managed to create a backup in the controller, were you using the FP SDK?

Are you trying to copy a backup file generated by the Flex Pendant?

Saludos/Carlos
