IStorageFolder.GetFileAsync(String) 方法

定義

從目前資料夾取得指定的檔案。

public:
 IAsyncOperation<StorageFile ^> ^ GetFileAsync(Platform::String ^ name);
/// [Windows.Foundation.Metadata.RemoteAsync]
IAsyncOperation<StorageFile> GetFileAsync(winrt::hstring const& name);
[Windows.Foundation.Metadata.RemoteAsync]
public IAsyncOperation<StorageFile> GetFileAsync(string name);
function getFileAsync(name)
Public Function GetFileAsync (name As String) As IAsyncOperation(Of StorageFile)

參數

name
String

Platform::String

winrt::hstring

相對於要擷取之檔案之目前資料夾) 的名稱 (或路徑。

傳回

當這個方法成功完成時,它會傳回代表檔案的 StorageFile

屬性

適用於

另請參閱