FileInformation FileInformation FileInformation FileInformation Class

Provides synchronous access to the properties exposed off StorageFile and lets an app perform asynchronous file operations such as copy, delete, move, and rename.

Syntax

Declaration

public sealed class FileInformationpublic sealed class FileInformationPublic NotInheritable Class FileInformation

Remarks

You can retrieve a list of FileInformation objects by calling one of the GetFilesAsync(System.UInt32,System.UInt32) methods.

Properties summary

Gets the attributes of a file.

Gets an object that contains the basic properties information of the file.

Gets a string that describes the contents of the file.

Gets the date that the file was created.

Gets the user-friendly name of the StorageFile.

Gets the display type of the StorageFile.

Gets an object that provides access to the document properties of the StorageFile, such as the title, author name, and so on.

Gets the file type.

Gets the identifier that uniquely identifies the StorageFile relative to other items in the same folder.

Gets the image properties of the StorageFile, such as the title, rating, date that the image was taken,

and so on.

Indicates if the current file has been downloaded or can be downloaded.

Gets the music properties associated with the StorageFile, such as the album name, artist name, bit rate, and so on.

Gets the name of the StorageFile.

Gets the path of the StorageFile.

Gets an object for retrieving the properties of the StorageFile.

Gets the StorageProvider object that contains info about the service that stores the current file.

Gets the thumbnail associated with the StorageFile.

Gets an object that provides access to the video properties of the StorageFile, such as the duration, rating, date released, and so on.

Methods summary

Replaces the specified StorageFile with a copy of the current file.

Creates a copy of the StorageFile and stores it in the specified StorageFolder.

Creates a copy of the StorageFile, gives it the specified file name, and stores it in the specified StorageFolder.

Creates a copy of the StorageFile, gives it the specified file name, and stores it in the specified StorageFolder. The method also specifies what to do if a file with the same name already exists in the specified folder.

Deletes a file.

Deletes a file, optionally moving the deleted file to the recycle bin.

Retrieves the basic properties of the StorageFile.

Gets the parent folder of the current file.

Retrieves the thumbnail that is associated with the StorageFile.

Retrieves the thumbnail that is associated with the StorageFile, scaling it to the specified size.

Retrieves the thumbnail that is associated with the StorageFile, based on the specified options.

Indicates whether the current file is the same as the specified storage item.

Determines whether the loaded StorageFile is the specified type.

Moves the current StorageFile from its location and uses it to replace the specified StorageFile.

Moves the StorageFile to the specified StorageFolder.

Moves the StorageFile to the specified folder, and gives the file the specified file name.

Moves the StorageFile to the specified folder and gives it the specified file name. The method also specifies what to do if a file with the same name already exists in the specified folder.

Opens a random-access stream with the specified options over the specified file.

Opens a random-access stream with the specified options over the specified file.

Opens a read-only, random-access stream over the StorageFile.

Opens a read-only, sequential-access stream over the StorageFile.

Opens a random-access stream to the file that can be used for transacted-write operations.

Opens a random-access stream to the file that can be used for transacted-write operations with the specified options.

Renames the StorageFile.

Renames the StorageFile, and specifies what to do if a file with the same name already exists in the current folder.

Events summary

Occurs when one or more of the StorageFile 's properties is updated.

Fires when the StorageFile 's thumbnail is updated or a better quality thumbnail is available.

Properties

  • Attributes
    Attributes
    Attributes
    Attributes

    Gets the attributes of a file.

    public FileAttributes Attributes { get; }public FileAttributes Attributes { get; }Public ReadOnly Property Attributes As FileAttributes

    Property Value

  • BasicProperties
    BasicProperties
    BasicProperties
    BasicProperties

    Gets an object that contains the basic properties information of the file.

    public BasicProperties BasicProperties { get; }public BasicProperties BasicProperties { get; }Public ReadOnly Property BasicProperties As BasicProperties

    Property Value

  • ContentType
    ContentType
    ContentType
    ContentType

    Gets a string that describes the contents of the file.

    public string ContentType { get; }public string ContentType { get; }Public ReadOnly Property ContentType As string

    Property Value

    • string
      string
      string
      string

      The content type string.

  • DateCreated
    DateCreated
    DateCreated
    DateCreated

    Gets the date that the file was created.

    public DateTime DateCreated { get; }public DateTime DateCreated { get; }Public ReadOnly Property DateCreated As DateTime

    Property Value

    Remarks

    If the date property isn't set, this value defaults to 0 which can be translated into misleading dates in different programming languages. In JavaScript, for example, 0 translates to December 16, 1600. You should always check that this property is a real value and not 0.

  • DisplayName
    DisplayName
    DisplayName
    DisplayName

    Gets the user-friendly name of the StorageFile.

    public string DisplayName { get; }public string DisplayName { get; }Public ReadOnly Property DisplayName As string

    Property Value

    • string
      string
      string
      string

      The user-friendly name of the StorageFile.

  • DisplayType
    DisplayType
    DisplayType
    DisplayType

    Gets the display type of the StorageFile.

    public string DisplayType { get; }public string DisplayType { get; }Public ReadOnly Property DisplayType As string

    Property Value

    • string
      string
      string
      string

      The display type.

  • DocumentProperties
    DocumentProperties
    DocumentProperties
    DocumentProperties

    Gets an object that provides access to the document properties of the StorageFile, such as the title, author name, and so on.

    public DocumentProperties DocumentProperties { get; }public DocumentProperties DocumentProperties { get; }Public ReadOnly Property DocumentProperties As DocumentProperties

    Property Value

  • FileType
    FileType
    FileType
    FileType

    Gets the file type.

    public string FileType { get; }public string FileType { get; }Public ReadOnly Property FileType As string

    Property Value

    • string
      string
      string
      string

      The file type.

  • FolderRelativeId
    FolderRelativeId
    FolderRelativeId
    FolderRelativeId

    Gets the identifier that uniquely identifies the StorageFile relative to other items in the same folder.

    public string FolderRelativeId { get; }public string FolderRelativeId { get; }Public ReadOnly Property FolderRelativeId As string

    Property Value

    • string
      string
      string
      string

      The folder-relative identifier.

  • ImageProperties
    ImageProperties
    ImageProperties
    ImageProperties

    Gets the image properties of the StorageFile, such as the title, rating, date that the image was taken,

    and so on.

    public ImageProperties ImageProperties { get; }public ImageProperties ImageProperties { get; }Public ReadOnly Property ImageProperties As ImageProperties

    Property Value

  • IsAvailable
    IsAvailable
    IsAvailable
    IsAvailable

    Indicates if the current file has been downloaded or can be downloaded.

    public bool IsAvailable { get; }public bool IsAvailable { get; }Public ReadOnly Property IsAvailable As bool

    Property Value

    • bool
      bool
      bool
      bool

      True if the file has been downloaded or can be downloaded. Otherwise, false.

  • MusicProperties
    MusicProperties
    MusicProperties
    MusicProperties

    Gets the music properties associated with the StorageFile, such as the album name, artist name, bit rate, and so on.

    public MusicProperties MusicProperties { get; }public MusicProperties MusicProperties { get; }Public ReadOnly Property MusicProperties As MusicProperties

    Property Value

  • Name
    Name
    Name
    Name

    Gets the name of the StorageFile.

    public string Name { get; }public string Name { get; }Public ReadOnly Property Name As string

    Property Value

    • string
      string
      string
      string

      The name.

  • Path
    Path
    Path
    Path

    Gets the path of the StorageFile.

    public string Path { get; }public string Path { get; }Public ReadOnly Property Path As string

    Property Value

    • string
      string
      string
      string

      The path.

  • Properties
    Properties
    Properties
    Properties

    Gets an object for retrieving the properties of the StorageFile.

    public StorageItemContentProperties Properties { get; }public StorageItemContentProperties Properties { get; }Public ReadOnly Property Properties As StorageItemContentProperties

    Property Value

  • Provider
    Provider
    Provider
    Provider

    Gets the StorageProvider object that contains info about the service that stores the current file.

    public StorageProvider Provider { get; }public StorageProvider Provider { get; }Public ReadOnly Property Provider As StorageProvider

    Property Value

  • Thumbnail
    Thumbnail
    Thumbnail
    Thumbnail

    Gets the thumbnail associated with the StorageFile.

    public StorageItemThumbnail Thumbnail { get; }public StorageItemThumbnail Thumbnail { get; }Public ReadOnly Property Thumbnail As StorageItemThumbnail

    Property Value

  • VideoProperties
    VideoProperties
    VideoProperties
    VideoProperties

    Gets an object that provides access to the video properties of the StorageFile, such as the duration, rating, date released, and so on.

    public VideoProperties VideoProperties { get; }public VideoProperties VideoProperties { get; }Public ReadOnly Property VideoProperties As VideoProperties

    Property Value

Methods

  • CopyAndReplaceAsync(Windows.Storage.IStorageFile)
    CopyAndReplaceAsync(Windows.Storage.IStorageFile)
    CopyAndReplaceAsync(Windows.Storage.IStorageFile)
    CopyAndReplaceAsync(Windows.Storage.IStorageFile)

    Replaces the specified StorageFile with a copy of the current file.

    public IAsyncAction CopyAndReplaceAsync(Windows.Storage.IStorageFile)public IAsyncAction CopyAndReplaceAsync(Windows.Storage.IStorageFile)Public Function CopyAndReplaceAsync(Windows.Storage.IStorageFile) As IAsyncAction

    Parameters

    Returns

  • CopyAsync(Windows.Storage.IStorageFolder)
    CopyAsync(Windows.Storage.IStorageFolder)
    CopyAsync(Windows.Storage.IStorageFolder)
    CopyAsync(Windows.Storage.IStorageFolder)

    Creates a copy of the StorageFile and stores it in the specified StorageFolder.

    public IAsyncOperation<StorageFile> CopyAsync(Windows.Storage.IStorageFolder)public IAsyncOperation<StorageFile> CopyAsync(Windows.Storage.IStorageFolder)Public Function CopyAsync(Windows.Storage.IStorageFolder) As IAsyncOperation( Of StorageFile )

    Parameters

    Returns

    • When this method completes successfully, it returns the copy as a StorageFile object.

  • CopyAsync(Windows.Storage.IStorageFolder,System.String)
    CopyAsync(Windows.Storage.IStorageFolder,System.String)
    CopyAsync(Windows.Storage.IStorageFolder,System.String)
    CopyAsync(Windows.Storage.IStorageFolder,System.String)

    Creates a copy of the StorageFile, gives it the specified file name, and stores it in the specified StorageFolder.

    public IAsyncOperation<StorageFile> CopyAsync(Windows.Storage.IStorageFolder,System.String)public IAsyncOperation<StorageFile> CopyAsync(Windows.Storage.IStorageFolder,System.String)Public Function CopyAsync(Windows.Storage.IStorageFolder,System.String) As IAsyncOperation( Of StorageFile )

    Parameters

    Returns

    • When this method completes successfully, it returns the copy as a StorageFile object.

  • CopyAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)
    CopyAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)
    CopyAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)
    CopyAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)

    Creates a copy of the StorageFile, gives it the specified file name, and stores it in the specified StorageFolder. The method also specifies what to do if a file with the same name already exists in the specified folder.

    public IAsyncOperation<StorageFile> CopyAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)public IAsyncOperation<StorageFile> CopyAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)Public Function CopyAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption) As IAsyncOperation( Of StorageFile )

    Parameters

    Returns

    • When this method completes successfully, it returns the copy as a StorageFile object.

  • DeleteAsync()
    DeleteAsync()
    DeleteAsync()
    DeleteAsync()

    Deletes a file.

    public IAsyncAction DeleteAsync()public IAsyncAction DeleteAsync()Public Function DeleteAsync() As IAsyncAction

    Returns

  • DeleteAsync(Windows.Storage.StorageDeleteOption)
    DeleteAsync(Windows.Storage.StorageDeleteOption)
    DeleteAsync(Windows.Storage.StorageDeleteOption)
    DeleteAsync(Windows.Storage.StorageDeleteOption)

    Deletes a file, optionally moving the deleted file to the recycle bin.

    public IAsyncAction DeleteAsync(Windows.Storage.StorageDeleteOption)public IAsyncAction DeleteAsync(Windows.Storage.StorageDeleteOption)Public Function DeleteAsync(Windows.Storage.StorageDeleteOption) As IAsyncAction

    Parameters

    Returns

  • GetBasicPropertiesAsync()
    GetBasicPropertiesAsync()
    GetBasicPropertiesAsync()
    GetBasicPropertiesAsync()

    Retrieves the basic properties of the StorageFile.

    public IAsyncOperation<BasicProperties> GetBasicPropertiesAsync()public IAsyncOperation<BasicProperties> GetBasicPropertiesAsync()Public Function GetBasicPropertiesAsync() As IAsyncOperation( Of BasicProperties )

    Returns

    • When this method completes successfully, it returns a BasicProperties object.

  • GetParentAsync()
    GetParentAsync()
    GetParentAsync()
    GetParentAsync()

    Gets the parent folder of the current file.

    public IAsyncOperation<StorageFolder> GetParentAsync()public IAsyncOperation<StorageFolder> GetParentAsync()Public Function GetParentAsync() As IAsyncOperation( Of StorageFolder )

    Returns

    • When this method completes, it returns the parent folder as a StorageFolder.

  • GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode)
    GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode)
    GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode)
    GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode)

    Retrieves the thumbnail that is associated with the StorageFile.

    public IAsyncOperation<StorageItemThumbnail> GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode)public IAsyncOperation<StorageItemThumbnail> GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode)Public Function GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode) As IAsyncOperation( Of StorageItemThumbnail )

    Parameters

    Returns

    • When this method completes successfully, it returns the thumbnail image as a StorageItemThumbnail object.

  • GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32)
    GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32)
    GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32)
    GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32)

    Retrieves the thumbnail that is associated with the StorageFile, scaling it to the specified size.

    public IAsyncOperation<StorageItemThumbnail> GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32)public IAsyncOperation<StorageItemThumbnail> GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32)Public Function GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32) As IAsyncOperation( Of StorageItemThumbnail )

    Parameters

    Returns

    • When this method completes successfully, it returns the thumbnail image as a StorageItemThumbnail object.

  • GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32,Windows.Storage.FileProperties.ThumbnailOptions)
    GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32,Windows.Storage.FileProperties.ThumbnailOptions)
    GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32,Windows.Storage.FileProperties.ThumbnailOptions)
    GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32,Windows.Storage.FileProperties.ThumbnailOptions)

    Retrieves the thumbnail that is associated with the StorageFile, based on the specified options.

    public IAsyncOperation<StorageItemThumbnail> GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32,Windows.Storage.FileProperties.ThumbnailOptions)public IAsyncOperation<StorageItemThumbnail> GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32,Windows.Storage.FileProperties.ThumbnailOptions)Public Function GetThumbnailAsync(Windows.Storage.FileProperties.ThumbnailMode,System.UInt32,Windows.Storage.FileProperties.ThumbnailOptions) As IAsyncOperation( Of StorageItemThumbnail )

    Parameters

    Returns

    • When this method completes successfully, it returns the thumbnail image as a StorageItemThumbnail object.

  • IsEqual(Windows.Storage.IStorageItem)
    IsEqual(Windows.Storage.IStorageItem)
    IsEqual(Windows.Storage.IStorageItem)
    IsEqual(Windows.Storage.IStorageItem)

    Indicates whether the current file is the same as the specified storage item.

    public bool IsEqual(Windows.Storage.IStorageItem)public bool IsEqual(Windows.Storage.IStorageItem)Public Function IsEqual(Windows.Storage.IStorageItem) As bool

    Parameters

    Returns

    • bool
      bool
      bool
      bool

      Returns true if the current storage item is the same as the specified storage item; otherwise false.

  • IsOfType(Windows.Storage.StorageItemTypes)
    IsOfType(Windows.Storage.StorageItemTypes)
    IsOfType(Windows.Storage.StorageItemTypes)
    IsOfType(Windows.Storage.StorageItemTypes)

    Determines whether the loaded StorageFile is the specified type.

    public bool IsOfType(Windows.Storage.StorageItemTypes)public bool IsOfType(Windows.Storage.StorageItemTypes)Public Function IsOfType(Windows.Storage.StorageItemTypes) As bool

    Parameters

    Returns

    • bool
      bool
      bool
      bool

      True if the loaded StorageFile is the specified type; otherwise false.

  • MoveAndReplaceAsync(Windows.Storage.IStorageFile)
    MoveAndReplaceAsync(Windows.Storage.IStorageFile)
    MoveAndReplaceAsync(Windows.Storage.IStorageFile)
    MoveAndReplaceAsync(Windows.Storage.IStorageFile)

    Moves the current StorageFile from its location and uses it to replace the specified StorageFile.

    public IAsyncAction MoveAndReplaceAsync(Windows.Storage.IStorageFile)public IAsyncAction MoveAndReplaceAsync(Windows.Storage.IStorageFile)Public Function MoveAndReplaceAsync(Windows.Storage.IStorageFile) As IAsyncAction

    Parameters

    Returns

  • MoveAsync(Windows.Storage.IStorageFolder)
    MoveAsync(Windows.Storage.IStorageFolder)
    MoveAsync(Windows.Storage.IStorageFolder)
    MoveAsync(Windows.Storage.IStorageFolder)

    Moves the StorageFile to the specified StorageFolder.

    public IAsyncAction MoveAsync(Windows.Storage.IStorageFolder)public IAsyncAction MoveAsync(Windows.Storage.IStorageFolder)Public Function MoveAsync(Windows.Storage.IStorageFolder) As IAsyncAction

    Parameters

    Returns

  • MoveAsync(Windows.Storage.IStorageFolder,System.String)
    MoveAsync(Windows.Storage.IStorageFolder,System.String)
    MoveAsync(Windows.Storage.IStorageFolder,System.String)
    MoveAsync(Windows.Storage.IStorageFolder,System.String)

    Moves the StorageFile to the specified folder, and gives the file the specified file name.

    public IAsyncAction MoveAsync(Windows.Storage.IStorageFolder,System.String)public IAsyncAction MoveAsync(Windows.Storage.IStorageFolder,System.String)Public Function MoveAsync(Windows.Storage.IStorageFolder,System.String) As IAsyncAction

    Parameters

    Returns

  • MoveAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)
    MoveAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)
    MoveAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)
    MoveAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)

    Moves the StorageFile to the specified folder and gives it the specified file name. The method also specifies what to do if a file with the same name already exists in the specified folder.

    public IAsyncAction MoveAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)public IAsyncAction MoveAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption)Public Function MoveAsync(Windows.Storage.IStorageFolder,System.String,Windows.Storage.NameCollisionOption) As IAsyncAction

    Parameters

    Returns

  • OpenAsync(Windows.Storage.FileAccessMode)
    OpenAsync(Windows.Storage.FileAccessMode)
    OpenAsync(Windows.Storage.FileAccessMode)
    OpenAsync(Windows.Storage.FileAccessMode)

    Opens a random-access stream with the specified options over the specified file.

    public IAsyncOperation<IRandomAccessStream> OpenAsync(Windows.Storage.FileAccessMode)public IAsyncOperation<IRandomAccessStream> OpenAsync(Windows.Storage.FileAccessMode)Public Function OpenAsync(Windows.Storage.FileAccessMode) As IAsyncOperation( Of IRandomAccessStream )

    Parameters

    Returns

    • When this method completes, it returns an IRandomAccessStream that contains the requested random-access stream.

  • OpenAsync(Windows.Storage.FileAccessMode,Windows.Storage.StorageOpenOptions)
    OpenAsync(Windows.Storage.FileAccessMode,Windows.Storage.StorageOpenOptions)
    OpenAsync(Windows.Storage.FileAccessMode,Windows.Storage.StorageOpenOptions)
    OpenAsync(Windows.Storage.FileAccessMode,Windows.Storage.StorageOpenOptions)

    Opens a random-access stream with the specified options over the specified file.

    public IAsyncOperation<IRandomAccessStream> OpenAsync(Windows.Storage.FileAccessMode,Windows.Storage.StorageOpenOptions)public IAsyncOperation<IRandomAccessStream> OpenAsync(Windows.Storage.FileAccessMode,Windows.Storage.StorageOpenOptions)Public Function OpenAsync(Windows.Storage.FileAccessMode,Windows.Storage.StorageOpenOptions) As IAsyncOperation( Of IRandomAccessStream )

    Parameters

    Returns

    • When this method completes, it returns an IRandomAccessStream that contains the requested random-access stream.

  • OpenReadAsync()
    OpenReadAsync()
    OpenReadAsync()
    OpenReadAsync()

    Opens a read-only, random-access stream over the StorageFile.

    public IAsyncOperation<IRandomAccessStreamWithContentType> OpenReadAsync()public IAsyncOperation<IRandomAccessStreamWithContentType> OpenReadAsync()Public Function OpenReadAsync() As IAsyncOperation( Of IRandomAccessStreamWithContentType )

    Returns

  • OpenSequentialReadAsync()
    OpenSequentialReadAsync()
    OpenSequentialReadAsync()
    OpenSequentialReadAsync()

    Opens a read-only, sequential-access stream over the StorageFile.

    public IAsyncOperation<IInputStream> OpenSequentialReadAsync()public IAsyncOperation<IInputStream> OpenSequentialReadAsync()Public Function OpenSequentialReadAsync() As IAsyncOperation( Of IInputStream )

    Returns

    • When this method completes successfully, it returns a read-only, sequential-access stream (type IInputStream ).

  • OpenTransactedWriteAsync()
    OpenTransactedWriteAsync()
    OpenTransactedWriteAsync()
    OpenTransactedWriteAsync()

    Opens a random-access stream to the file that can be used for transacted-write operations.

    public IAsyncOperation<StorageStreamTransaction> OpenTransactedWriteAsync()public IAsyncOperation<StorageStreamTransaction> OpenTransactedWriteAsync()Public Function OpenTransactedWriteAsync() As IAsyncOperation( Of StorageStreamTransaction )

    Returns

    • When this method completes, it returns a StorageStreamTransaction that contains the random-access stream and methods that can be used to complete transactions.

  • OpenTransactedWriteAsync(Windows.Storage.StorageOpenOptions)
    OpenTransactedWriteAsync(Windows.Storage.StorageOpenOptions)
    OpenTransactedWriteAsync(Windows.Storage.StorageOpenOptions)
    OpenTransactedWriteAsync(Windows.Storage.StorageOpenOptions)

    Opens a random-access stream to the file that can be used for transacted-write operations with the specified options.

    public IAsyncOperation<StorageStreamTransaction> OpenTransactedWriteAsync(Windows.Storage.StorageOpenOptions)public IAsyncOperation<StorageStreamTransaction> OpenTransactedWriteAsync(Windows.Storage.StorageOpenOptions)Public Function OpenTransactedWriteAsync(Windows.Storage.StorageOpenOptions) As IAsyncOperation( Of StorageStreamTransaction )

    Parameters

    Returns

    • When this method completes, it returns a StorageStreamTransaction that contains the random-access stream and methods that can be used to complete transactions.

  • RenameAsync(System.String)
    RenameAsync(System.String)
    RenameAsync(System.String)
    RenameAsync(System.String)

    Renames the StorageFile.

    public IAsyncAction RenameAsync(System.String)public IAsyncAction RenameAsync(System.String)Public Function RenameAsync(System.String) As IAsyncAction

    Parameters

    • desiredName
      System.String
      System.String
      System.String
      System.String

      The new name.

    Returns

  • RenameAsync(System.String,Windows.Storage.NameCollisionOption)
    RenameAsync(System.String,Windows.Storage.NameCollisionOption)
    RenameAsync(System.String,Windows.Storage.NameCollisionOption)
    RenameAsync(System.String,Windows.Storage.NameCollisionOption)

    Renames the StorageFile, and specifies what to do if a file with the same name already exists in the current folder.

    public IAsyncAction RenameAsync(System.String,Windows.Storage.NameCollisionOption)public IAsyncAction RenameAsync(System.String,Windows.Storage.NameCollisionOption)Public Function RenameAsync(System.String,Windows.Storage.NameCollisionOption) As IAsyncAction

    Parameters

    Returns

Events

  • PropertiesUpdated
    PropertiesUpdated
    PropertiesUpdated
    PropertiesUpdated

    Occurs when one or more of the StorageFile 's properties is updated.

    public event TypedEventHandler PropertiesUpdatedpublic event TypedEventHandler PropertiesUpdatedPublic Event PropertiesUpdated
  • ThumbnailUpdated
    ThumbnailUpdated
    ThumbnailUpdated
    ThumbnailUpdated

    Fires when the StorageFile 's thumbnail is updated or a better quality thumbnail is available.

    public event TypedEventHandler ThumbnailUpdatedpublic event TypedEventHandler ThumbnailUpdatedPublic Event ThumbnailUpdated

Device family

Windows 10 (introduced v10.0.10240.0)

API contract

Windows.Foundation.UniversalApiContract (introduced v1)

Attributes

Windows.Foundation.Metadata.ContractVersionAttribute

Details

Assembly

Windows.Storage.BulkAccess.dll