April 11, 2010

[SOLVED]How to determine screen size programmatically

@Override
public void onCreate(Bundle icicle) {
. . .
WindowManager w = getWindowManager();
Display d = w.getDefaultDisplay();
int width = d.getWidth();
int height = d.getHeight();
.

How to determine screen resolution programmatically - Android Developers Google Groups.

No comments:

Post a Comment