Community discussions

MikroTik App
 
pikpik
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 80
Joined: Wed Jan 20, 2010 11:25 am

Syntax problem

Wed Aug 24, 2016 2:08 pm

:if ([/ping 8.8.8.8 count=5 routing-table=WAN1 ] = 0) do={
/ip route disable [find where comment="Brama_domyslna"]
}
else {
/ip route enable [find where comment="Brama_domyslna"]
}
syntax error (line 4 column 6)
Why syntax error ? I also tried
else={
CRS125/ROS 6.36
 
User avatar
mrz
MikroTik Support
MikroTik Support
Posts: 7056
Joined: Wed Feb 07, 2007 12:45 pm
Location: Latvia
Contact:

Re: Syntax problem

Wed Aug 24, 2016 2:36 pm

closing brace and else must be on the same line.
 
pikpik
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 80
Joined: Wed Jan 20, 2010 11:25 am

Re: Syntax problem

Wed Aug 24, 2016 2:49 pm

Solved but LOL :)

Who is online

Users browsing this forum: eldoncito2019 and 70 guests