Dialog code needed - Discuss

Hello
Does anybody know how to code a dialog from the niotron ide?
Thank you.

1 Like

Here’s a straightforward method for creating a basic AlertDialog:

AlertDialog alertDialog = new AlertDialog.Builder(form).create();
alertDialog.setTitle("Alert");
alertDialog.setMessage("Alert message to be shown");
alertDialog.setButton(AlertDialog.BUTTON_NEUTRAL, "OK",
    new DialogInterface.OnClickListener() {
        @Override
        public void onClick(DialogInterface dialog, int which) {
            dialog.dismiss();
        }
    });
alertDialog.show();
1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.