GDFileIOWriteBufferAsync Method |
Namespace: GD
public static IAsyncAction WriteBufferAsync( IGDStorageFile file, IBuffer buffer )
using GD; ... try { var file = await GDWindows.Instance.SecureFolder.CreateFileAsync("foo.bar"); if (file != null) { IBuffer buffer = GetBufferFromString("Swift as a shadow"); await GDFileIO.WriteBufferAsync(file, buffer); // Perform additional tasks after file is written } } // Handle errors with catch blocks catch (FileNotFoundException) { // For example, handle file not found }