Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default text columns in one cell

does anybody know how to write in ''two columns in one cell'' ?
for better understanding my problem, i'll try to describe:
need to write first and last name in one cell
when write another name in second row, i want to have
firt character of name under first character of name in first row and
first character of last name under first character of last name in first row

inserting and merging columns is not impossible

thanks


  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default text columns in one cell

Hmmm...

You could do this with a helper column and set the helper column to use a
fixed width font like Courier.

See this screencap:

http://img156.imageshack.us/img156/2203/alignedzk0.jpg

In the formula, change the 7 to the length of the *longest* first name. In
the screencap William is the longest first name and is 7 characters long.

--
Biff
Microsoft Excel MVP


"DzEK" wrote in message ...
does anybody know how to write in ''two columns in one cell'' ?
for better understanding my problem, i'll try to describe:
need to write first and last name in one cell
when write another name in second row, i want to have
firt character of name under first character of name in first row and
first character of last name under first character of last name in first
row

inserting and merging columns is not impossible

thanks




  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default text columns in one cell

that's what i need!!
i type exactly, but don't work !!!
:-(
works with office 2000?


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default text columns in one cell

You have to format the formula cells to use a fixed width font. In the
example I used COURIER.

--
Biff
Microsoft Excel MVP


"DzEK" wrote in message ...
that's what i need!!
i type exactly, but don't work !!!
:-(
works with office 2000?




  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default text columns in one cell

in format cell choose font and set courier for whole column
but still don't work!!

any idea?

many thanks for your attention!




  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default text columns in one cell

What does "don't work" mean?

Post the *exact* formula you tried.

This will only work on 2 word names like John Smith. If you have 3 or even 4
word names I don't know how you'd do this.

--
Biff
Microsoft Excel MVP


"DzEK" wrote in message ...
in format cell choose font and set courier for whole column
but still don't work!!

any idea?

many thanks for your attention!




  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default text columns in one cell

hi, valko

i wrote ''don't work'' because i got message - formula error !!

this is 'formula' (copy -paste)


=LEFT(A1,FIND(" ",A1)-1&REPT(" ",8-LEN(LEFT(A1,FIND("
",A1)-1))+1)&MID(A1,FIND(" ",A1)+1,255)



  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default text columns in one cell

Ok, you're missing a ")"

Here is the formula in "chunks" so that line wrap (hopefully) won't remove
the *necessary* space characters. Also note, I've made a slight change by
removing "+1" in two places:

=LEFT(A1,FIND(" ",A1)-1)&
REPT(" ",8-LEN(LEFT(A1,FIND(" ",A1)-1)))&
MID(A1,FIND(" ",A1),255)

Also of note, we can calculate which first name is the longest and build
that into the formula *but* this will add more complexity to the formula and
will make it an array formula**:

=LEFT(A1,FIND(" ",A1)-1)&
REPT(" ",MAX(LEN(LEFT(A$1:A$3,FIND(" ",A$1:A$3)-1)))
-LEN(LEFT(A1,FIND(" ",A1)-1)))&
MID(A1,FIND(" ",A1),255)

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER)

Or, you can use a helper cell to calculate the longest first name and then
refer to that cell:

B1 = array formula** :

=MAX(LEN(LEFT(A1:A3,FIND(" ",A1:A3)-1)))

Then (normally entered):

=LEFT(A1,FIND(" ",A1)-1)&
REPT(" ",B$1-LEN(LEFT(A1,FIND(" ",A1)-1)))&
MID(A1,FIND(" ",A1),255)


--
Biff
Microsoft Excel MVP


"DzEK" wrote in message ...
hi, valko

i wrote ''don't work'' because i got message - formula error !!

this is 'formula' (copy -paste)


=LEFT(A1,FIND(" ",A1)-1&REPT(" ",8-LEN(LEFT(A1,FIND("
",A1)-1))+1)&MID(A1,FIND(" ",A1)+1,255)





  #9   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default text columns in one cell

i tried your suggestion, but nothing happened...except formula error!

=LEFT(A1,FIND(" ",A1)-1&REPT(" ",8-LEN(LEFT(A1,FIND("
",A1)-1))+1)&MID(A1,FIND(" ",A1)+1,255)


A1,FIND became blackmarked!

also A3,FIND in 'your' formula

=MAX(LEN(LEFT(A1:A3,FIND(" ",A1:A3)-1)))


any new idea?

thanks in advance!



  #10   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default text columns in one cell

If you are getting errors flagged at that stage, I wonder whether your
Windows Regional Settings are defining the list separator as semi-colon
instead of comma?
If so, you'll need to separate parameters in your formulae by semi-colons
instead of commas.
--
David Biddulph

"DzEK" wrote in message ...
i tried your suggestion, but nothing happened...except formula error!

=LEFT(A1,FIND(" ",A1)-1&REPT(" ",8-LEN(LEFT(A1,FIND("
",A1)-1))+1)&MID(A1,FIND(" ",A1)+1,255)


A1,FIND became blackmarked!

also A3,FIND in 'your' formula

=MAX(LEN(LEFT(A1:A3,FIND(" ",A1:A3)-1)))


any new idea?

thanks in advance!







  #11   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default text columns in one cell

Here's a small sample file that demonstrates this:

align.xls 15kb

http://cjoint.com/?ccxSV3KVt3


--
Biff
Microsoft Excel MVP


"DzEK" wrote in message ...
i tried your suggestion, but nothing happened...except formula error!

=LEFT(A1,FIND(" ",A1)-1&REPT(" ",8-LEN(LEFT(A1,FIND("
",A1)-1))+1)&MID(A1,FIND(" ",A1)+1,255)


A1,FIND became blackmarked!

also A3,FIND in 'your' formula

=MAX(LEN(LEFT(A1:A3,FIND(" ",A1:A3)-1)))


any new idea?

thanks in advance!





  #12   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default text columns in one cell

i made change you suggest

now have another error

#VALUE!


???

:-(

##$%&#!!


  #13   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default text columns in one cell

yes !!!
works!

have no words to express my thankfulness

:-D



  #14   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default text columns in one cell

You're welcome. Thanks for the feedback!

--
Biff
Microsoft Excel MVP


"DzEK" wrote in message ...
yes !!!
works!

have no words to express my thankfulness

:-D





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
Comparing columns of text: cell value into array Myo_77 Excel Discussion (Misc queries) 0 December 5th 07 11:56 AM
Separate cell text FirstnameLastname into two columns drewannie Excel Discussion (Misc queries) 3 July 6th 06 07:37 PM
how do I copy text to columns from one cell to another? Stressed! Excel Discussion (Misc queries) 8 May 11th 06 08:01 PM
Each rows last cell text value could be in any columns. Robert Christie Excel Worksheet Functions 6 May 2nd 06 06:53 PM
Seperating of Text in one cell into two columns Mistys template Excel Worksheet Functions 1 January 27th 05 04:06 PM


All times are GMT +1. The time now is 08:46 AM.

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

About Us

"It's about Microsoft Excel"