Promotic
WikipediaLinkedInYoutubeTwitterFacebook

do...while - statement of language JavaScript

Description:
Repeats a block of statements while the condition is true..
Syntax:
do (condition)
{
  [statements]
}
 
also the following syntax can be used, where the condition is at the end:
do
{
  [statements]
}
while (condition)
 
condition Numeric or string expression that is true or false.
statements One or more statements that are repeated while the condition is true or until the condition is not true.
Note:
For similar purpose in the VBScript language is used the statement Do...Loop.
See also:
Example1:
Statements in cycle 1 - 6
var i=1, sBoil;
do (i<=6)
{
  sBoil = "Boiler "+i;
  i++;
}
Example2:
or
var i=1, sBoil;
do
{
  sBoil = "Boiler "+i;
  i++;
}
while (i<=6)
PROMOTIC 8.3.21 SCADA system documentation - MICROSYS, spol. s r.o.

Send page remarkContact responsible person
© MICROSYS, spol. s r. o.Tavičská 845/21 703 00 Ostrava-Vítkovice