Sort a listbox by last name VB

I have an app that has a listbox. It uses an sql datasource that populates with the full name column data. I have a user that wants the listbox to sort by the last name instead of the first name. Is that possible?
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

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.

Anil GolamariCommented:

You can sort the list on SQL end before loading it into listbox. Because Once loaded if you have full name as "Last Name + First Name" you should be able to sort it but I don't think we can do it other way round.

David Johnson, CD, MVPOwnerCommented:
if the table is  only Name nvarchar(max) and not firstname nvarchar(max), lastname nvarchar(max) the answer is not really possible
ICantSeeAuthor Commented:
Basically what we are saying is if the data is entered into the table as lastname+firstname it will sort by the lastname. Otherwise this is difficult to do... correct?
David Johnson, CD, MVPOwnerCommented:
correct  we could create a temp table and try and split the first and last name but items such as initials, middle name, degrees and names with spaces in them
john doe, jane smith  easy to split
john doe, jane smith, george washington carver  more complex
john doe, jane smith, george washington carver, george c. Scott
john doe, jane smith, george washington carver, george c. Scott, John Paul LLD
john doe, jane smith, george washington carver, george c. Scott, John Paul LLD, Hansel Adolf von Richtofen

we have to cover all eventualities of a name.

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
ICantSeeAuthor Commented:
This is a new application so there is very little data in the table. I will instruct the users to enter the name as last name + first Name.

thank you for the help
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

From novice to tech pro — start learning today.