Community discussions

MikroTik App
 
peektoseen
just joined
Topic Author
Posts: 19
Joined: Fri Jul 22, 2011 5:03 pm

Execute if wireless interface is exist.

Fri May 15, 2015 9:44 am

Hello.
I try made script, which execute command if wireless interface (/interface wireles) is exist, something like this:
:if ( wireless_is_exist ) do={ :put "lala" }
but I can't invent condition, can you please help me with this question?
 
User avatar
PaulsMT
MikroTik Support
MikroTik Support
Posts: 282
Joined: Tue Feb 10, 2015 3:21 pm

Re: Execute if wireless interface is exist.

Fri May 15, 2015 12:16 pm

This will check if the board has wireless interface.

{
:do {
:if ([:len [/interface wireless find ]]>0) do={:put "wireless found"}} on-error={:put "No wireless interface found"};
}
 
peektoseen
just joined
Topic Author
Posts: 19
Joined: Fri Jul 22, 2011 5:03 pm

Re: Execute if wireless interface is exist.

Tue May 19, 2015 10:56 am

This will check if the board has wireless interface.

{
:do {
:if ([:len [/interface wireless find ]]>0) do={:put "wireless found"}} on-error={:put "No wireless interface found"};
}
Thank you very much!

Who is online

Users browsing this forum: No registered users and 30 guests