How to retrieve information from database and display it in textview spinner? I'm using android studio. I entering all the information using asqlite manager downloaded from the playstore. Below is some of the codes for main activity
private void displayCurrentNearableInfo() {
Desc = (TextView) findViewById(R.id.textview1); //for description
// Get reference of SpinnerView from layout/nearable_demo.xml
spinnerDropDown = (Spinner) findViewById(R.id.spinner1); //For size available
spinnerDropDown2 = (Spinner) findViewById(R.id.spinner2);//for colours available
COO = (TextView) findViewById(R.id.textview2);//for country of origin
SM = (TextView) findViewById(R.id.textview3); //for shoe model
Price = (TextView) findViewById(R.id.textview4); //for price
stickerdb = new Database_sticker(this);
dbRow = stickerdb.getResult(currentNearable.identifier);
dbRow.getDesc();
dbRow.getSa();
dbRow.getCa();
dbRow.getCoo();
dbRow.getSm();
dbRow.getPrice();
}
Cheers Keke
Aucun commentaire:
Enregistrer un commentaire