Get Path From URI In Kotlin Android

When we pick an image, video, audio, or any other file from the gallery or documents directory we receive URI in intent in the onActivityResult(…) method. So we always further required to get a full file path from that URI. If we directly try to get the path through URI.getData() method, it doesn’t serve the […]

Capture Photo with Camera in Kotlin – Android

This article shows a step by step guide to capture a photo with camera in Android using Kotlin. For this purpose, we need to initialize an Intent with MediaStore.ACTION_IMAGE_CAPTURE Action. Then open native Camera App using startActivityForResult(…), as shown in the following code. 1. Add Camera Permission Before starting, add the following CAMERA permission in your Manifest.xml file […]

Begin typing your search term above and press enter to search. Press ESC to cancel.