Search code examples
androidsqliteseekbar

Change SeekBar position using TextView in Android


I want to change the position of a seekbar according to a textview. I am making a prediction app in which I am using a seekbar and when I change the seekbar position the TextView value is changing. I am storing this value in SQLite and when I rerun the app the last prediction shows on the TextView but the seekbar position remains constant. How can I change the position of the seekbar according to the TextView?


Solution

  • seekBar.setProgress(Integer.parseInt(textView.getText().toString()));