I have some data in the form of text w/ 8 letters. I'd like to insert a hyphen after the third character. Is this possible using a formula to populate an entire field? Example:
Current format: ABC01234
Desired format: ABC-01234
I have some data in the form of text w/ 8 letters. I'd like to insert a hyphen after the third character. Is this possible using a formula to populate an entire field? Example:
Current format: ABC01234
Desired format: ABC-01234
Last edited by Brahma72472; 12-30-2008 at 12:18 PM.
Try:
=REPLACE(A1,4,0,"-")
where A1 contains original
Where there is a will there are many ways.
If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner
Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.
Wow...u guys/gals are awesome. The replace function worked brilliantly. Thanks for the help!!!
If you are satisfied with the solution(s) provided, please mark your thread as Solved.
How to mark a thread Solved
Go to the first post
Click edit
Click Go Advanced
Just below the word Title you will see a dropdown with the word No prefix.
Change to Solved
Click Save
Is it possible to insert that "=replace(..)" formula within an IF formula? I sometimes have spreadsheets that will have values in column A, but only in some of the rows. I'd like to be able to say If there's a value in column A, insert a '-' between characters 3 and 4. I like working with formulas where possible and avoiding macros.
Thanks!
Welcome to the Forum, unfortunately:
Your post does not comply with Rule 2 of our Forum RULES. Don't post a question in the thread of another member -- start your own thread. If you feel it's particularly relevant, provide a link to the other thread. It makes sense to have a new thread for your question because a thread with numerous replies can be off putting & difficult to pick out relevant replies.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks