LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #11   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,651
Default Custome Format Alpha

On Sun, 09 Mar 2008 16:19:57 -0400, Ron Rosenfeld
wrote:

=IF(AND(ISNUMBER(-LEFT(A1,11)),ISTEXT(RIGHT(A1,1)),LEN(A1)=12),
TEXT(LEFT(A1,11),"00-000000000-")& RIGHT(A1,1),"invalid entry")


Better with:

=IF(AND(ISNUMBER(-LEFT(A1,11)),ISERR(-RIGHT(A1,1)),LEN(A1)=12),
TEXT(LEFT(A1,11),"00-000000000-")& RIGHT(A1,1),"invalid entry")

--ron
 
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
Is it possible to format a cell to keep alpha characters only? Crankn Excel Discussion (Misc queries) 0 January 29th 10 04:02 PM
Custome Format Hal Excel Discussion (Misc queries) 2 September 21st 09 02:59 PM
Alpha Charachters in Format Cells Custom Paul Moles Excel Worksheet Functions 3 February 16th 08 12:40 PM
How do I format a column in alpha order? Marian New Users to Excel 3 April 2nd 06 05:15 PM
Custome Number format based on Value Dr. Sachin Wagh Excel Discussion (Misc queries) 2 February 17th 06 11:24 AM


All times are GMT +1. The time now is 03:56 PM.

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"