

I anycodings_android mean to put spinner value to district_id anycodings_android instead of district_id it self. I anycodings_android need to pass the spinner value to textView anycodings_android with name throw the code: anycodings_android "params.put("district_id", district_id) ". First of all create a database in MS SQL with name MyDatabase and create following table with name countries. In this post I will be explaining how to fill Data in a spinner. To achieve the same thing, I think ListPopupWindow is a good replacement.I have a spinner with name on anycodings_android activity with name (activity_add_comp). In my previous posts I explained How to connect Android with MS SQL Database, Simple Login application in android using MS SQL Database.

drop down height, the first item will be selected when loading data. I think Spinner isn't a flexible android widget as not many settings available, e.g. 60 items, then android:overlapAnchor="false" doesn't satisfy your requirement as no enough space for drop down list and it's the similar situation when spinner sits at the bottom, but with drop down list above spinner. Step 2 Add the following code to res/layout/activitymain.xml. In the loop create a new EditText prgramatically and add to the linearlayout by using myLayout.addView(myEditText). Step 1 Create a new project in Android Studio, go to File New Project and fill all required details to create a new project. Programatically if user enters n number then take loop upto n. If the spinner layout is around the center of screen with many items, e.g. This example demonstrates how do I make an android spinner with initial default text in android. If the spinner layout is at the top of screen, then android:overlapAnchor="false" is enough It depends on where your spinner is located and how many items in the drop down list.
