Limit keys in textfield?

Hello,
I have the following code which limits the keys which can be entered into a textfield.
How do I allow the keys A-F?

[code] Dim skipKey As Boolean = True // Disallow all keys by default

If Key >= “0” And Key <= “9” Then skipKey = False
If Key = “.” Then skipKey = False
If Key = “-” Then skipKey = False
If Key = Chr(8) Then skipKey = False // BackSpace
If Key = Chr(127) Then skipKey = False // Delete

Return skipKey[/code]

Thank you all in advance.

Look at this:
http://documentation.xojo.com/index.php/TextEdit.Mask
It explains how to limit the text which can be entered.

Thanks, I decided to check for each key char individually.

skipKey=(instr("0123456789.-"+chrb(8)+chrb(127),key)=0)