troubleshooting Question

Excel 2007 macro to change headers in work sheet

Avatar of Serena2345
Serena2345Flag for United States of America asked on
Microsoft Excel
4 Comments3 Solutions343 ViewsLast Modified:
I have a reports program that produces header like this
Pay Group - Job Dta      Autolink File Number - Job Dta      Empl ID      Name - Personal Dta      Action - Job Dta      Action Date - Job Dta      Department ID - Job Dta      Location Code - Job Dta      State - Location Info      State - Personal Dta      State Tax Code - Tax Dta      State2 Tax Code - Tax Dta
I need a macro that can go to the header row and delete and text to the right of the  "-" and leave the text to the left.
Any help would be appreciated.
Glenn Ray
US Data Team Lead
Join our community to see this answer!
Unlock 3 Answers and 4 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 3 Answers and 4 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros