View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Pete_UK Pete_UK is offline
external usenet poster
 
Posts: 8,856
Default Is it possible...

With the word instructor in A1, this formula:

=TEXT(CODE(UPPER(A1))-64,"00")

will return 09 for the first character in that word. You can use MID
to select different letters from the word. However, there is not a
multi-concatenation function in Excel to join those two-digit strings
together, so you would need a user-defined function to do what you
want. Presumably you would not want to include spaces or other
punctuation symbols? You can always wrap LEFT around the function to
limit the length of the returned string.

Hope this helps.

Pete

On Apr 14, 10:19*am, "John Smith" wrote:
To convert a text value to a number using a defined rule in Excel, say a
macro or some other formula? Take for example, say the value "Instructor"
mapping to 09141920182103201518 with each letter corresponding to its
position in the alphabet represented by a two digit number. However, the
longer the word, the longer the numerical string, so I would like to be able
to limit this in some way.

I do not yet know which words or phrases will be entered, but is there some
hash function available that will keep the numeric strings relatively short?