You can use the Before Update event of the control to do this. The only
drawback is whether the possibility exists that the entered text could
contain the string spa that should not be transformed, but you will have to
deal with that.
Private Sub txtSomeControl_BeforeUpdate(Cancel As Integer)
If Instr(Me.txtSomeControl, "spa") > 0 Then
Me.txtSomeControl = Replace(Me.txtSomeControl,"spa", "S.p.A.")
ElseIf Instr(Me.txtSomeControl, "srl") > 0 Then
Me.txtSomeControl = Replace(Me.txtSomeControl,"srl", "S.r.L.")
ElseIf Instr(Me.txtSomeControl, "snc") > 0 Then
Me.txtSomeControl = Replace(Me.txtSomeControl,"srl", "s.n.c.")
End If
End Sub
Add whatever other values you need to convert.

Signature
Dave Hargis, Microsoft Access MVP
> Hi to everyone in the Newsgroup,
>
[quoted text clipped - 27 lines]
> Thanks,
> Stefano.
Jeff Boyce - 21 Sep 2007 23:12 GMT
A minor detail/typo, I suspect...
I think the third replace needs to replace "snc" rather than "srl". Drat
that Copy/Paste <g>!
Jeff Boyce
> You can use the Before Update event of the control to do this. The only
> drawback is whether the possibility exists that the entered text could
[quoted text clipped - 46 lines]
>> Thanks,
>> Stefano.
riccifs@tin.it - 22 Sep 2007 08:24 GMT
> A minor detail/typo, I suspect...
>
[quoted text clipped - 57 lines]
> >> Thanks,
> >> Stefano.
Hi Jeff,
many thanks to have answered me, but I'm still not understanding very
well what I have to do.
Could you give to me more instructions on how to do, please?
Bye,
Stefano.
P.S.
I'm not very good VBA code builder, so I need a step by step help!
Jeff Boyce - 24 Sep 2007 23:02 GMT
Stefano
What Dave suggested is to add an event procedure to the Before Update event
of the text control on your form in which the users will be entering the
codes. If you don't have any experience creating (and troubleshooting!)
VBA, it could be a bit of a learning curve.
Fortunately, you can copy and paste his code, making changes appropriate to
the names of your objects.
Potentially, another approach might be to create a table that hold two
fields. One field is the abbreviation, the other is the description. Then
you could use a combo box on your form to let the users select what they
need to use, rather than having to enter something (and have you, via code,
have to modify it).
Good luck!
Regards
Jeff Boyce
Microsoft Office/Access MVP
>> A minor detail/typo, I suspect...
>>
[quoted text clipped - 70 lines]
> P.S.
> I'm not very good VBA code builder, so I need a step by step help!