Sunday 15 July 2012

android - ProgressBar ontop of TableLayout -


I am trying to close my progress above a table layout.

Code:

  & lt ;? Xml version = "1.0" encoding = "UTF-8"? & Gt; & Lt; LinearLayout xmlns: android = "Http://schemaskandroidkcom/apk/res/android" Android: Layout_width = "Fill_parent" Android: Layout_height = "Fill_parent" Android: baselineAligned = "false" android: orientation = "vertical" & Gt; & Lt; ProgressBar Android "Android: attr / progressBarStyleLarge" id = "@ + id / bar_Update" style = Android: Layout_width = "Wrap_content" Android: Layout_height = "Wrap_content" android: padding = "250dp" Android: visibility = "visible" / & Gt; & Lt; ScrollView android: id = "@ + id / ScrollView01" Android: layout_width = "wrap_content" Android: layout_height = "wrap_content" & gt; & Lt; Android: layout_height = "wrap_content" android: shrinkColumns = "*" Android: stretchColumns = "*" Android: Gravity = "center_horizontal" Android: layout_gravity: TableLayout Android: id = "@ + id / tableLayout1" Android: layout_width = "fill_parent" = "Top" & gt; & Lt; TableRow android: id = "@ + id / rowtolele" Android: layout_width = "wrap_content" Android: layout_height = "wrap_content" & gt; & Lt; TextView android: id = "@ + id / title" Android: Layout_width = "Fill_parent" Android: layout_height = "60px" android: gravity = "center" android: text = "Unterichtsausfall: \ n" Android: textSize = "20 DP "Android: Textstyle =" Bold "Android: Typeface =" Serif "& gt; & Lt; / TextView & gt; & Lt; imageView android: id = "@ + id / imgUpdate" Android: layout_width = "wrap_content" Android: layout_height = "wrap_content" Android: adjustViewBounds = "false" Android: baselineAlignBottom = "false" android: clickable = "true" Android : Src = "@Drawable / Refresh" /> & Lt; / TableRow & gt; & Lt; / TableLayout & gt; & Lt; / Scrollview & gt; & Lt; / LinearLayout & gt;   

I in your code to display the progress bar at the top of the layout Set visibility (see. Visual) I am using , but it does not work is. Gone to display it, I'm using setVisibility (see. INVISIBLE) . What am I doing wrong? My goal is to get data from the internet right now showing the spinner. As soon as the data is received, it is displayed in the table and the spinner goes.

Thank you!

"" on top and "above" generally means that Usually, on the 'top' it usually means the graphics given below is included, because one usually wants to do one progress with Barrar.

'Up', usually above the top of the screen means high, so that ScrollView and Table layout will be close to the bottom of the screen.

If your progress was 'at the top', then see . INVISIBLE will be OK. But, your progress bar is above the layout below. Therefore, the way you have implemented, you should set it to View.GONE to hide it.


If you want to display the progress bar, the 'over the top, or your layout over the bottom, the top-level layout of a RelativeLayout a LinearLayout instead.


In the end, I do not understand what is wrong. Is not actually working with your layout or code behavior?

No comments:

Post a Comment