Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel,microsoft.public.excel.worksheet.functions
Veronika
 
Posts: n/a
Default Validation of Postal Code

Hi;

is there a way to validate CND postal codes in a spreadsheet? If not how can
I format the column to accept only A9A9A9 type of data? (Upper case,
number,uppercase, etc.)
Thank you,

Veronika


  #2   Report Post  
Posted to microsoft.public.excel,microsoft.public.excel.worksheet.functions
Debra Dalgleish
 
Posts: n/a
Default Validation of Postal Code

You can use the custom data validation formula that J.E. McGimpsey shows
in this message:


http://groups.google.ca/group/micros...d254817?hl=en&

If you want to check for upper case, you can add the Exact function to
the formula. However, the formula would then be too long for the data
validation formula box:


=AND(EXACT(A1,UPPER(A1)),(LEFT(A1)="A")*(LEFT(A1) <="Z")*(MID(A1,2,1)="0")*(MID(A1,2,1)<="9")*(

MID(A1,3,1)="A")*(MID(A1,3,1)<="Z")*(MID(A1,4,1) ="0")*(MID(A1,4,1)<="9

")*(MID(A1,5,1)="A")*(MID(A1,5,1)<="Z")*(MID(A1,6 ,1)="0")*(MID(A1,6,1)
<="9")*(LEN(A1)=6))

You could enter the formula in an adjacent cell, and in the cell where
the postal code is entered, use data validation to check that the
formula result is true.

Veronika wrote:
Hi;

is there a way to validate CND postal codes in a spreadsheet? If not how can
I format the column to accept only A9A9A9 type of data? (Upper case,
number,uppercase, etc.)
Thank you,

Veronika




--
Debra Dalgleish
Excel FAQ, Tips & Book List
http://www.contextures.com/tiptech.html

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Validation code for macro to run [email protected] Excel Discussion (Misc queries) 1 December 9th 05 02:28 PM
Change case...help please Terry Excel Worksheet Functions 14 October 2nd 05 12:29 PM
Macro for changing text to Proper Case JPriest Excel Worksheet Functions 3 August 8th 05 09:31 PM
Using other workbooks.. DavidMunday Excel Worksheet Functions 2 July 1st 05 07:35 AM
Make Change Case in Excel a format rather than formula Kevin Excel Worksheet Functions 1 March 18th 05 08:53 PM


All times are GMT +1. The time now is 10:52 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"