I have following code:
var bootboxresult;
bootbox.prompt('Please enter some data', function(result) {
if (result != null) {
bootboxresult = result;
}});
alert(bootboxresult);
if(bootboxresult === null)
{
return;
}
if(bootboxresult != null)
{
Some Code To Excecute
}
The code displays the prompt box, but always the content of the "bootboxresult" variable is null or undefined.
I need that the further code should wait for the bootbox.prompt() to store the value in the "bootboxresult" variable.
Please advise.