David T.

asked • 03/16/23

Reformatting words in a cell

In cell A1, it says "269 Southwest 13th Avenue, Pompano Beach, FL".

In cell A2, I want it to be reformatted to "Pompano Beach, FL; 269 Southwest 13th Avenue".

What formula would I use to reformat?


3 Answers By Expert Tutors

By:

Jason L. answered • 08/04/23

Tutor
New to Wyzant

David L. answered • 05/18/23

Tutor
New to Wyzant

Joseph S. answered • 03/18/23

Tutor
New to Wyzant

Joseph S.

Let’s explain what this formula does: The MID function will extract text from a given string (in this case the text in cell A1) at a location starting from a given character number in the string for a certain number of characters. The SEARCH function will search a given string and return the number of the character where it's located. If there is no such character it will return the #VALUE error. The LEN function will return the number of characters in a given string. The LEFT function will extract text starting at the first character in the string for a certain number of characters. The text in A1 is: "269 Southwest 13th Avenue, Pompano Beach, FL" The location where the text should be captured for the new cell is 2 characters past the comma (after the comma and the blank space). The first part of the formula looks at cell A1 text, finds the location of the comma, then starting at the character two spaces later returns the remaining text in the cell. (Note this is assured since whatever length is left will certainly be less the the length of the original text in A1.) Then the captured string is concatenated by adding a comma and a space. then the left most part of the original text up to the character just before the comma.
Report

03/18/23

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.