FileManager
The FileManager is an extension class which can be used to save/load your RadDiagram in a file on your Disk or in your application's IsolatedStorage.
Properties
- CurrentFile: A property of type string that gets or sets the current file path.
Methods
FileManager class exposes two methods: LoadFromFile and SaveToFile. Depending on the parameter of these methods, the XML string can be saved to two storage locations: Disk or IsolatedStorage.
LoadFromFile(FileLocation location = FileLocation.Disk): This method accepts an enum of type FileLocation. By default the FileManager will load the XML string from the hard drive.
SaveToFile(FileLocation location = FileLocation.Disk): This method accepts an enum of type FileLocation. By default the FileManager will save the XML string to the hard drive.
To demonstrate this extension we are going to create a very simple application. First we can go ahead and declare the RadDiagram in XAML and add some shapes. Then we can add two buttons for save and load behavior.