Script to basically swap first two columns of table

G

ganesha108

Version: 2008
Operating System: Mac OS X 10.5 (Leopard)
Processor: Intel

Hi everyone. I don't know much about excel and need a script to rearrange this sheet. Am using excel 2008.

It is (x is a series values):
1, a, x, x, x, x,
1, b, x, x, x, x,
1, c, x, x, x, x,
2, a, x, x, x, x,
2, b, x, x, x, x,
2, c, x, x, x, x,
3, a, x, x, x, x,
3, b, x, x, x, x,
3, c, x, x, x, x,

And needs to be:
a, 1, x, x, x, x,
a, 2, x, x, x, x,
a, 3, x, x, x, x,
b, 1, x, x, x, x,
b, 2, x, x, x, x,
b, 3, x, x, x, x,
c, 1, x, x, x, x,
c, 2, x, x, x, x,
c, 3, x, x, x, x,

I hope it makes sense. Thanks.
 
C

CyberTaz

Well, the need makes sense, but why a script?

Assuming the content is in A1:F50, for example:

Select A1:A50, Cut
Control/Right-Click cell C1
Choose Insert Cut Cells

HTH |:>)
Bob Jones
[MVP] Office:Mac
 
G

Guest

Thanks CyberTaz.

I wasn't sure what I needed.

I tried your suggestion but it doesn't work. I get a pop up box "This selection is not valid". Any other ideas?

Thanks.

Well, the need makes sense, but why a script?





Assuming the content is in A1:F50, for example:





Select A1:A50, Cut Control/Right-Click cell C1 Choose Insert Cut Cells





HTH |:>) Bob Jones [MVP] Office:Mac








1, a, x, x, x, x, > 1, b, x, x, x, x, > 1, c, x, x, x, x, > 2, a, x,
x, x, x, > 2, b, x, x, x, x, > 2, c, x, x, x, x, > 3, a, x, x, x, x, >
3, b, x, x, x, x, > 3, c, x, x, x, x,
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top