View Single Post
06-29-10, 03:24 PM   #240
Lordyfrb
A Cliff Giant
AddOn Author - Click to view addons
Join Date: Apr 2008
Posts: 71
Thats ok I'm not to sure about lua syntax.

However I've spotted a spelling mistake in your code:
Code:
        OnLoad=function(self)
            self:RegsiterEvent'CHAT_MSG_CHANNEL_NOTICE'
        end,
        OnEvent=function(self)
            if event == "CHAT_MSG_CHANNEL_NOTICE" then
            if arg1 == "YOU_JOINED" and arg7 == 2 then
                Recount_MainWindow:Hide()
            elseif arg1 == "YOU_LEFT" and arg7 == 2 then
                Recount_MainWindow:Show()
                end
            end
        end,
should be:
Code:
        OnLoad=function(self)
            self:RegisterEvent'CHAT_MSG_CHANNEL_NOTICE'
        end,
        OnEvent=function(self)
            if event == "CHAT_MSG_CHANNEL_NOTICE" then
            if arg1 == "YOU_JOINED" and arg7 == 2 then
                Recount_MainWindow:Hide()
            elseif arg1 == "YOU_LEFT" and arg7 == 2 then
                Recount_MainWindow:Show()
                end
            end
        end,
See if that helps.
  Reply With Quote