Dart has equivalent MessageBox functionality, as in C #, using WinForms

I know that there is a MessageBox class in the isolation library, but that is not what I need. I am looking for pop-up message functionality found in Windows Windows applications (such as WinForm applications), where you ask a simple confirmation question and the user can click Yes or No in response. Is there an equivalent to dart if someone cannot offer some alternatives?

+4
source share
1 answer

You can easily display a message box with:

window.alert('test'); 

don't forget about it at the top of the file:

 import 'dart:html'; 

This will behave as a warning function in JavaScript. If you want to add buttons to the message window (others, and then the "ok" button by default), you will need to create your own window, which will not be very difficult. You create an element that you add to the body of the document. This element must be absolute. Adding an overlay in front of your document will be useful to prevent users from clicking on the page.

this is in javascript, but it is useful to know what to do with dom and css:

http://raventools.com/blog/create-a-modal-dialog-using-css-and-javascript/

+7
source

All Articles