matchtext command
Posted: Tue Aug 18, 2015 5:34 pm
Hello!
I'm using the matchtext command in my card's script (below). Can someone explain to me what I'm doing wrong here? I get the same error (below below) whether the username already exists in fld "user list" or not.
I've tested this command a dozen different ways as a single line in the message box and I get no problems. As a side note, as a total beginner, what is an effective way to debug this kind of problem myself?
error
I'm using the matchtext command in my card's script (below). Can someone explain to me what I'm doing wrong here? I get the same error (below below) whether the username already exists in fld "user list" or not.
I've tested this command a dozen different ways as a single line in the message box and I get no problems. As a side note, as a total beginner, what is an effective way to debug this kind of problem myself?
Code: Select all
on adduser # Click btn Add User, adds new user to fld User List with basic info
global gName
ask "What is your username?" # select unique username
put it into gName
matchtext(fld "user list",gName)
if it is false then
choosepassword
else if it is true then
answer "Username unavailable. Please choose another username." with "OK"
exit adduser
end if
end adduser
handler: can't find handler
object: login
matchtext(fld "user list",gName)