MS Excel Help

Associate
Joined
3 Feb 2003
Posts
1,771
Location
Sydney, Australia
Doing some work at the moment and wondering if one of you lovely lot would be able to save me some time.

I have an excel workbook that contains account numbers in it. I need to slightly change their format so that I can use them on a template to upload into my accounting package at work.

Currently they look like this:

380200185040000

but I need them to look like this:

38020-0185040-000

I have about 20 sheets with an assload of accounts on each. Is there a macro or something I could run to insert the -'s?

The formulas I'm using at the moment involve me creating 3 extra columns and it's driving me nuts the amount of time it's taking.


Cheers
 
Spot on Bond!

That worked an absolute treat :cool:


That's actually what I was doing but with seperate columns for each step, I didn't realise you could link them together like that. :rolleyes: I swear I learn something new about excel every time I use it.

Thanks
 
It works something along the lines of

"take the first five characters starting from the left - in cell A1"
"then add a '-'"
"then starting from the fifth character in cell A1, take the next 8 characters"
"then add another '-'"
"finally starting from the thirteenth character in A1, take the next 3 characters"
 
Back
Top Bottom