With the number of all works and does not work with string.
dialog("Hope this helps");
function dialog(nw) {
temp = nw.toString()
alert(temp);
var dlg=
"dialog{text:'Script Interface',bounds:[100,100,570,250],"+
"panel0:Panel{bounds:[10,10,460,140] , text:'' ,properties:{borderStyle:'etched',su1PanelCoordinates:true},"+
"statictext0:StaticText{bounds:[10,10,300,30] , text:'Запись в словаре отсутствует, добавить запись?' ,properties:{scrolling:undefined,multiline:undefined}},"+
"statictext1:StaticText{bounds:[10,30,150,50] , text:'',properties:{scrolling:undefined,multiline:undefined}},"+
"edit0:EditText{bounds:[10,55,320,75] , text:'',properties:{multiline:false,noecho:false,readonly:false}},"+
"button1:Button{bounds:[10,85,220,110] , text:'Добавить' },"+
"button2:Button{bounds:[230,85,440,110] , text:'Игнорировать' }}};";
var win= new Window(dlg,"Добавление записи");
win.panel0.statictext1.text = nw;
win.panel0.edit0.text = nw;
win.center();
var done = false;
while (!done) {
var x = win.show();
if (x == 0 || x == 2) {
win.canceled = true;
done = true;
} else if (x == 1) {
done = true;
var result = validate();
if(result != true) {
alert(result);
return;
}else
{
}
}
}
function validate(){
return true;
}
}