How to Take Screenshot of Android Application in Android Emulator and Real Device from Android Studio

How to Take Screenshot of Android Application From Android StudioHow to Take Screenshot From Android Studio


Taking screenshot from android studio is very easy and screen can be taken in any android emulator or any real device, just follow these simple steps:

Step 1: Open android studio and run your application just by clicking run button.



Step 2: After running your application, click Android tab on the left bottom of android studio. That will bring up the DDMS window and it looks like screenshot given below.



Android Studio DDMS window


Step 3: Now click Screen Capture icon on the left side of Android DDMS tool window and it looks like screenshot given below.


Android Studio- Screen Capture


Step 4: After clicking Screen Capture icon there appears new window with screenshot image of your application it looks like screenshot given below.


Android Studio Screen Capture


Note:  If you need to add a device frame around your screenshot, enable the frame screenshot option and choose different device.

Step 5: Now click Save button and choose directory to save your screenshot.

How to extract filename from Uri?

Now, we can extract filename with and without extension :) You will convert your bitmap to uri and get the real path of your file. Now w...