I am trying to use an IF / ELES formula in JavaScript to autopopulate a text field in a table, but I keep getting a syntax error.
Could someone please help?
and I want to write a specific text on cells from an table, but before I want to check if this cell was empty or not, if empty (this cell1.rawValue = "text") eles must go to cell 2 and testing eles to the next. And so on.
Tabel1
1 | yes |
2 | no |
tabel2|
cell1 | "text" |
cell2 | |
cell3 | |
cell4 |
something close to this may can help you understand me more: (this is not really code)
if tabel1.rawValue = 1
and if tabel2.cell1.rawValue == null then
tabel2.cell1.rawValue = "text"
else
if tabel2.cell2.rawValue == null then
tabel2.cell2.rawValue = "text"
eles
if tabel2.cell3.rawValue == null then
tabel2.cell3.rawValue = "text"
eles
if tabel2.cell4.rawValue = null then
tabel2.cell4.rawValue = "text"
eles
{
xfa.host.messageBox("There is no space in the table!!!");
}
thnak you! i wish you can help me!
Solved! Go to Solution.
Hi there,
before understanding syntax in JavaScript, there is basics you should understand with the operators
JavaScript Operators :
JavaScript Syntax :
'then' is omitted in JavaScript and { } is used instead
don't forget to put the end of line (semicolon) on each line (excluding statements (if, switch, else, else if, etc...))
To help you understand how to fix your JavaScript syntax, you can use syntax validator such as, Esprima: Syntax Validator
Any other information on JavaScript syntax can be found on google, W3Schools is a good start
Hope this will help!
PLEASE!!!! is there anyone can help me to fix it?...
why there is no answer??????
Views
Replies
Total Likes
Hi there,
before understanding syntax in JavaScript, there is basics you should understand with the operators
JavaScript Operators :
JavaScript Syntax :
'then' is omitted in JavaScript and { } is used instead
don't forget to put the end of line (semicolon) on each line (excluding statements (if, switch, else, else if, etc...))
To help you understand how to fix your JavaScript syntax, you can use syntax validator such as, Esprima: Syntax Validator
Any other information on JavaScript syntax can be found on google, W3Schools is a good start
Hope this will help!
Thank you a lot Magus069you are an super its working
Views
Replies
Total Likes
Views
Likes
Replies