How to make edittext in dialog in Sketchware

To add a edittext in Sketchware, follow the steps given below.

1. Add a dialog with ID dialog.
2. Add button, title,message in dialog.
3. Under the title section(if dialog only haves title) add the code below with add source directly block.
final EditText
myedittext = new EditText
(Activitynamehere.this);
dialog.setView(myedittext);
Now in place of Activitynamehere add the Activity name.  To use this, paste the code in when button OK clicked. Please use code below👇
mytext = 
myedittext.getText().to
String();

View on Github

Now add everything what will happen next.


Done!

Save and run the project.


Didn't understand? Watch video below.




Comments

Popular posts from this blog

How to use request network for webview in Sketchware

How to make a browser in sketchware