Jump to content

help guiSetText [urgent]solved


Anubhav

Recommended Posts

ok I was making a login GUI with tabs and some memo in it.

I have 2 client files:

gui.lua

client_handler.lua

gui.lua loads first and has the memo

  
GUIEditor.memo[2] = guiCreateMemo(0, 0, 806, 535, "", false, GUIEditor.tab[3])    
guiMemoSetReadOnly(GUIEditor.memo[2], true) 
  

but now I want to set the text of the memo in client_handler.lua, I get no error and it's still blank. ( I have outputted the text and it seemed fine. The text was pretty long.

  
function guiSetStaffList( list ) 
    local setText = "" 
    local timesDone = 0 
    for i,v in ipairs( list ) do 
        if timesDone == 0 then 
            setText = v.Rank..": "..v.Players 
            timesDone = timesDone + 1 
        else 
            setText = setText.."\n\n\n\n"..v.Rank..": "..v.Players 
            timesDone = timesDone + 1 
        end 
    end 
    guiSetText(GUIEditor.memo[2], setText ) 
end 
  

.

I have tried outputting setText, it WORKS VERY FINE with outputChatBox but why isn't the text set.

I also tried setting it in gui.lua by calling function FROM client_handler.lua but it still din't work!

Edited by Guest
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...