Code example for SeekBar

Methods: setLayoutParamssetMaxsetProgress

0
				LinearLayout.LayoutParams.FILL_PARENT,
				LinearLayout.LayoutParams.WRAP_CONTENT));
		// layout.setMinimumWidth(400); 
		layout.setPadding(20, 20, 20, 20);
 
		mSeekBar = new SeekBar(mContext);
		mSeekBar.setLayoutParams(new ViewGroup.LayoutParams(
				ViewGroup.LayoutParams.FILL_PARENT,
				ViewGroup.LayoutParams.WRAP_CONTENT));
 
		mSeekBar.setMax(mStartMax);
		mSeekBar.setProgress(mStartProgress);
		layout.addView(mSeekBar);
 
		builder.setView(layout);
		super.onPrepareDialogBuilder(builder);
	} 
 
	public void setDefaults(int progress, int max) {
		mStartMax = max;
Stop searching for code, let great code find you!  Add Codota to your java IDE