How get email address in a single cell separated by a semi-colon and a space

I have an Excel file with email addresses in a column.  I want to get them into a single cell separated by a semi-colon and a space.  How can I do this?
SteveL13Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Saurabh Singh TeotiaCommented:
Two ways to do this..

1. Column-B using a formula approach..Check row-->5

2. Column-C Using a userdefined formula for it..enclosed is the same for your reference..

Function combine(rng As Range)

    Dim cell As Range
    Dim str As String

    For Each cell In rng
        If cell.Value <> "" Then
            If str = "" Then
                str = cell.Value
            Else
                str = cell.Value & " ; " & str
            End If
        End If

    Next cell
    combine = str
End Function

Open in new window


Enclosed is the workbook for your reference..

Saurabh...
Combine.xlsm
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Excel

From novice to tech pro — start learning today.