First you need to get the WindowManager by : WindowManager wm = getSystemService(Context.WINDOW_SERVICE);
Next use the method to retrieve a Display object: Display d = wm.getDefaultDisplay(); ... and finally the resolution: int height = d.getHeight(); int width = d.getWidth(); Hope that helps. On 5 Sty, 15:17, Nico <nicolas.d...@gmail.com> wrote: > Hi, > I need to get the screen resolution, how can I get it ? > Thx. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---