如何透過 ContentResolver 取得真實檔名 === ```java= Uri contentUri = data.getdata(); DocumentFile documentFile = DocumentFile.fromSingleUri(this, contentUri); String fileName = documentFile.getName(); ``` ## Ref. [ContentResolver - how to get file name from Uri](https://stackoverflow.com/a/57901851/11827511) ###### tags: `File 相關`
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up