I wondered about the use of Dim within a keypress event e.g: Public Sub EditArea_KeyPress() Dim x as integer BLA BLA DO WHATEVER End And whether or not this was bad practice, or if one should use a public variable declared at the top of the program. Regards Richard