Empty variables in Log parser script

I need to do some action when user is disconnected from may wlan
I have been suggested to start with this article:
https://wiki.mikrotik.com/wiki/Log_Parser_-_Event_Trigger_Script

So i have followed the article. I have:

  • created buffer in memory,
  • added a topics=wireless,info ,
  • created Log Parser Script (identical as in the wiki)
  • created Parser Action Script (there i have removed almost all if construction and edit one “:if ([:tostr $logTopics] = “wireless;info”) do={ …”)
    Tried to edit second script plenty of times, and still can’t reach the “do={…” construction.

I have went further and checked the:
:global logParseVar
:local logTime [:pick [:toarray $logParseVar] 0]
:local logTopics [:pick [:toarray $logParseVar] 1]
:local logMessage [:pick [:toarray $logParseVar] 2]

As it turned out, the :global logParseVar contains only:
jul/26/2017 ,

But why :local logTopics [:pick [:toarray $logParseVar] 1] and :local logMessage [:pick [:toarray $logParseVar] 2] are empty??
Maybe someone may help with this as well?

Also why time in the jul/26/2017 format and not in the 16:16:22 as it is in the console??

HI.
I found a solution on this forum.
Change your scripts like here => http://forum.mikrotik.com/t/bug-tostr-variable-does-not-work-in-6-6/71447/1
Search the forum is really useful :slight_smile: