inser column T

add an column blank between

this is how is

a12.PNG

this is how should be  

b12.PNGinsercolumn.xlsx
ADRIANA PACCOUNTING ASSISTANTAsked:
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.

Roy CoxGroup Finance ManagerCommented:
Not sure what you mean, but maybe

   
 Sheet1.Columns("T:T").Insert Shift:=xlToRight, CopyOrigin:=xlFormatFromLeftOrAbove

Open in new window

0
ADRIANA PACCOUNTING ASSISTANTAuthor Commented:
Roy Cox

Thnks for the fast reponse

could be an button  to  add the columns

between the data
0
Roy CoxGroup Finance ManagerCommented:
Well, just add a button and attach the code
insercolumn.xlsm
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

ADRIANA PACCOUNTING ASSISTANTAuthor Commented:
Roy Cox

need be for each column with data
0
Roy CoxGroup Finance ManagerCommented:
What do you mean? You asked to insert Column T
0
Roy CoxGroup Finance ManagerCommented:
Do you mean like this

Edit, corrected code
insercolumn.xlsm
0
Subodh Tiwari (Neeraj)Excel & VBA ExpertCommented:
Like this?
insercolumn.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
NerdsOfTechTechnology ScientistCommented:
0
Fabrice LambertFabrice LambertCommented:
@Roy:
At least, provide a safe code:
Sub RectangleRoundedCorners1_Click()
    Dim Col As Long
    
    With ThisWorkbook.Sheets(1)
        Col = .Cells(6, .Columns.Count).End(xlToLeft).Column

        For Col = 2 To Col Step 2
            .Columns(Col).Insert Shift:=xlToRight
        Next
    End With
End Sub

Open in new window

0
Roy CoxGroup Finance ManagerCommented:
What???
0
Fabrice LambertFabrice LambertCommented:
@NerdsOfTech:
Alas, not everyone have the liberty to install 3rd party Tools or add-in. Nice link tho.

@Roy:
The global Columns collection implicitly refer to the ActiveWorkbook.ActiveWorksheet.Columns collection.
Wich guarantee do you have that ActiveWorkbook is the workbook holding the code ?
And wich guarantees do you have that ActiveWorksheet is the one one wich the code will be applied ?
0
Roy CoxGroup Finance ManagerCommented:
The button is on the sheet, so to click it  the workbook must be active and the sheet must be active!
1
Subodh Tiwari (Neeraj)Excel & VBA ExpertCommented:
@Roy
You only missed a dot before columns, nothing else.
Don't take him seriously. Cool. :)
1
Fabrice LambertFabrice LambertCommented:
@Roy:
This is a special use case (Ok, I admit it happen most of the time).
What if the function is called from somewhere else ?
0
Roy CoxGroup Finance ManagerCommented:
Not my problem, Adriana asked for a button so my comments stand
1
ADRIANA PACCOUNTING ASSISTANTAuthor Commented:
Great Job!

;)

Best Experts !

 Roy Cox, Fabrice Lamber  , Subodh Tiwari (Neeraj)
0
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
VBA

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.