hi , i am creating a Image view through code dynamically based on certain condition as below:
ImageView t = new ImageView(mContext); t.setLayoutParams(new LinearLayout.LayoutParams(390, 300)); the width and height is in PX i.e 390 PX and 300 PX but i want to know how to set width and height in dp instead of px programmatically . In xml we can do but i have no idea how to do it in code please help me . Thanks Mansoor V.M -- 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