Jump to content

Restrict Input Characters


'LinKin

Recommended Posts

I extracted this from an old script i made. You might find it helpful.

  
if string.find(guiGetText(source),"%W") then 
    guiSetEnabled(NextStepchoosenameTXT,false) 
    guiStaticImageLoadImage(NextStepchoosename,"pictures/button_disabled.png") 
    guiSetText(errorOutput,"Your first name must not contain non-alphanumeric characters!") 
end 
  

http://www.lua.org/pil/20.2.html - patterns are explained here

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...