Skip to main content

Add SeekBar Inside Dialog Box

Add SeekBar Inside Dialog Box 





If you haven`t yet watched the video,Watch it Now...!





Open your Sketchware project.Add Dialog Box component.
Go to the logic section & add the blocks which are necessary to create a dialog box.







Now you have to make some modifications.In order to add SeekBar you have to use add source directly block.Add the following code inside it.Please watch the above video for reference



final SeekBar cb1 = new SeekBar(MainActivity.this);
LinearLayout.LayoutParams lpar = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.WRAP_CONTENT, LinearLayout.LayoutParams.WRAP_CONTENT);
cb1.setLayoutParams(lpar);
dialog.setView(cb1);

Inside the block "dialog OK Button Clicked", add the following code using add source directly block


textview1.setText(String.valueOf(cb1.getProgress()));





Thats It :)



Now Run your Application




If you have any doubts comment below .

Comments

  1. Nice blog . I have also been making tutorials related to Sketchware. In my Sketchware Interface video I have explaines each and every part of the Sketchware app itself. Do check my channel to learn more about sketchware.
    My channel link - https://youtube.com/channel/UCOUL_rPb3vQZoQ_ENC9lB3w

    Thanks Sanjeev sir. I have learnt about sketchware by watching your videos . So Thanks a lot.

    ReplyDelete
  2. Deberías de poner capturas

    ReplyDelete

Post a Comment

Did you like this tutorial ?