Change Letter

GavZ

Mostly Beginners Luck!
Local time
Today, 05:01
Joined
May 4, 2007
Messages
56
Hi - Is it possible to change a letter to two leeters up from what you type?

For example when you type an 'a' you get a 'c'

Thanks in advance
 
use the keypress event and echo chr$(KeyAscii+3) to the control.

This should point you in the right direction
 
You can use the KeyDown event for that, something like
Code:
Private Sub YourControlName_KeyDown(KeyCode As Integer, Shift As Integer)
    KeyCode = KeyCode + 2
End Sub

You will need some kind of check for results after the Z.
 
Thats brill - Thanks both!!
 
I have got it to work ok with the keypress function and chr$(KeyAscii+3)

Is it possible to do the above and change each letter of a string with a button?
 
Cheers Dave but can you post it in A97 please
Thanks
Gav
 
Access 97... is that still around?

The attachment has been converted but not tested (I dont have A97 on any of my PC's) You may have to reset references.

Dave
 

Attachments

Thats Great - Have to work in A97 at work - cheapskates wont buy a newer version!

Thanks Gav
 
I use it to store logon passwords in a table. I thought that storing the actual password was a bit obvious, so I use this method to store and retreive them.
 

Users who are viewing this thread

Back
Top Bottom