Thanks that works fine as long as it take 2 cells to do it in. In Access we
used to be able to design a "special format" for such.
> Use the UPPER function: if "a1b 6c3" (no quotes, of course) is entered in
> A1, then in B1, =UPPER(A1) produces A1B 6C3
[quoted text clipped - 12 lines]
> > case.
> > Is this possible. Thanks
Dave Thomas - 23 Jul 2007 05:22 GMT
Excel is a number cruncher. Data validation in Excel is, for all practical
purposes, almost non-existent unless you use VBA code. Even the data
validation on the Data Menu which allows some validation is weak as you can
paste bad data into a cell even though the cell has data validation because
the data validation is ignored on a paste. Go figure! So, if you really need
to validate your data, learn Visual Basic for Applications.
Regards,
Dave
.
> Thanks that works fine as long as it take 2 cells to do it in. In Access
> we
[quoted text clipped - 19 lines]
>> > case.
>> > Is this possible. Thanks
T. Valko - 23 Jul 2007 05:39 GMT
I didn't think they wanted "validated" data. I thought they just wanted
something to automatically convert the entry to uppercase. If they do want
"validated" data then they'll have to wait for a good programmer to stop by!

Signature
Biff
Microsoft Excel MVP
> Excel is a number cruncher. Data validation in Excel is, for all practical
> purposes, almost non-existent unless you use VBA code. Even the data
[quoted text clipped - 32 lines]
>>> > case.
>>> > Is this possible. Thanks
Dave Thomas - 23 Jul 2007 05:41 GMT
Would a plan of attack be to enter the data in Access, do the data
validation, and then import the data into Excel?
> Thanks that works fine as long as it take 2 cells to do it in. In Access
> we
[quoted text clipped - 19 lines]
>> > case.
>> > Is this possible. Thanks
Gord Dibben - 23 Jul 2007 21:57 GMT
Fritz
There is no Custom Format for Canadian Postal codes that I have found.
You can use event code in the worksheet so that as you enter the code, it will
change to A1A 1A1
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
If Target.Column <> 1 Then Exit Sub
On Error GoTo ErrHandler
Application.EnableEvents = False
With Target
.Formula = UCase(Target.Formula)
.Value = (Left(Target.Value, 3) & " " & Right(Target.Value, 3))
End With
ErrHandler:
Application.EnableEvents = True
End Sub
As written this event code operates on Column A only.
You can type the code in as upper or lower case. Will come out as upper case no
matter what.
Right-click on the sheet tab and "View Code"
Copy/paste the above into that sheet module.
Adjust for your column if needed.
i.e. for just column B edit to If Target.Column <> 2 Then Exit Sub
Gord Dibben MS Excel MVP..................and Canuck
>Thanks that works fine as long as it take 2 cells to do it in. In Access we
>used to be able to design a "special format" for such.
[quoted text clipped - 15 lines]
>> > case.
>> > Is this possible. Thanks