Hi.
Can anyone tell me how to put one "Backspace" into a Text fiield, or, delete the last character entered in a text field? I have tried:
put backspaceKey into fld "Text" but the entire Field is deleted. I cannot use the "delete char" function as the character number is always changing.
Thanks for any help.
Cheers
Bidge
EDIT: Ahh....I've managed to figure it out
delete last char of field "Text"
BackSpace Key help
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Re: BackSpace Key help
Need to put this code on the field
but i have no ideea how to delete a current char now ..(example if you press 2x left button and after press backspace ..this function will delete the last char,no current char)
Greetings!
Razvan
Code: Select all
on backspacekey
if the selectedText is not empty
then delete the selectedText
else
delete the last char of me
end if
end backspacekey
Greetings!
Razvan
Re: BackSpace Key help
Hi Razvan,
not sure I understand you, but this sounds like the solution to me:
Best
Klaus
not sure I understand you, but this sounds like the solution to me:
Code: Select all
on backspacekey
if the selectedText is not empty then
delete the selectedText
else
## Let the OS do the right thing:
PASS backspacekey
end if
end backspacekey
Klaus
Re: BackSpace Key help
Thanks Klaus,
Your code is working well.
Your code is working well.