Take the 2-minute tour ×

I'm trying to write an app for my Samsung Vibrant (running android 2.1). I used the example "Form Stuff" app available as tutorial on the android developers website. I basically added a background picture to the application. the background picture has some text on it towards the top. I want to display a list of elements (to be selectable by teh user) but I want this list to start from a certain position on the screen (say for example - start from the middle of the screen). tried reading the listview under dev resource and searched the forums but I could not find a way to do this.

Could anyone please help me out? or if this is not possible, then suggest me something else which i can place at a certain position on the screen.

share|improve this question

2 Answers 2

You can use following logic,e.g

LinearLayout.LayoutParams lp=new LinearLayout.LayoutParams(100, 200);

etc..... this workd for me

share|improve this answer

you can try using setSelection(position) property available on listview

share|improve this answer

Your Answer


