This is just a simple script, since I'm new at coding in Google Script. I used their code to test a dialog, but the dialog window doesn't even open. Obviously I'm missing a piece of code, but am at a loss as to what. Here's my code. Thanks in advance!
function demoUI() {
var myapp = UiApp.createApplication().setTitle('An improved GUI');
var mygrid = myapp.createGrid(3, 2);
mygrid.setWidget(0, 0, myapp.createLabel('Name:'));
mygrid.setWidget(0, 1, myapp.createTextBox());
mygrid.setWidget(1, 0, myapp.createLabel('Age:'));
mygrid.setWidget(1, 1, myapp.createTextBox());
mygrid.setWidget(2, 0, myapp.createLabel('City'));
mygrid.setWidget(2, 1, myapp.createTextBox());
var mybutton = myapp.createButton('Press me');
var mypanel = myapp.createVerticalPanel();
mypanel.add(mygrid);
mypanel.add(mybutton);
myapp.add(mypanel);
return myapp;
}