android - creating dynamic resizable layout based on content -


I am trying to create a layout, which is the current 3 hours text with time and date along with the room number Shows

Possible Screen: Enter image details here

The room and the time / date are always stationary on the top and the rest will be dynamic by calling the SSL.

  data = idleResponse.getJSONArray ("lecture"); ArrayList & LT; String & gt; Lects = new arreelist & lt; String & gt; (); For (int i = 0; i & lt; data.length (); i ++) {JSONObject jObj = data. GetJSONObject (i); String time = jObj.getString ("starttime"); // to do.substring (0, 4); String module name = jObj.getString ("moduleName"); Lects.add (time + + + modulation); } String [] lecture list = new string [lects.size ()]; For (int i = 0; i & lt; lects.size (); i ++) {// Fill the list with data lecture [i] = lects.get (i); } Lecture.setText ("Upcomming lecture:"); // List view view list to see list = (list view) findViewById (R.id.listView1); ArrayAdapter & LT; String & gt; Adapters = new arreptopter & lt; String & gt; (This, Android .R.T. Syiml_list_item_1, lecture list); Listitems.setAdapter (adapter);  

I tried to implement it with list view, although it only minimizes a small part of the screen based on the number of elements.

Enter image details here

Because you only see it Can come down.

I was wondering what would be the best layout for this type of problem, all my layouts are very basic and something like that is a challenge for me. Thank you.

You must type your adapter for the list and use the wet property for the layout of each row.


Comments