PLACE TEXT RIGHT: place a character to the right in same place

itr674

Well-known Member
Joined
Apr 10, 2002
Messages
1,786
Office Version
  1. 2016
Platform
  1. Windows
I am trying to put asingle text character al the way right when using "courier new" itlines up in he same place.

The setup is:

Name cell: Last, First
Group cell: can be character two, three, or fourcharacters, and will be listed first

Using FIND to get just the LEN of Last nameand comma


Example of what Iwould like it to look like.


ABCD Last Name x

ABC Last Name x
AB LastName x
 
Last edited:

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
Is this what you mean


Book1
ABCD
2ABCDMaryxABCD Mary x
3ABCMungoxABC Mungo x
4ABMidgexAB Midge x
Sheet2
Cell Formulas
RangeFormula
D2=REPLACE(REPT(" ",10),1,LEN(A2),A2)&REPLACE(REPT(" ",10),1,LEN(B2),B2)&C2


PS:
It doesn't look as though it's lined up, but it will be in the sheet.
 
Last edited:
Upvote 0
You're welcome & thanks for the feedback
 
Upvote 0
If interested, here is a shorter version that I think should still do the job.

Excel Workbook
ABCD
2ABCDMaryxABCDMaryx
3ABCMungoxABCMungox
4ABMidgexABMidgex
Align
 
Upvote 0
If interested, here is a shorter version that I think should still do the job.
And here is another one that is way, way shorter. :devilish:

=REPLACE(A2&REPT(" ",20-LEN(A2))&C2,11,LEN(B2),B2)
 
Last edited:
Upvote 0

Forum statistics

Threads
1,212,927
Messages
6,110,733
Members
448,294
Latest member
jmjmjmjmjmjm

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top