write a macro to insert columns based on Cell Values

vpapolu

New Member
Joined
May 2, 2014
Messages
3
I have a worksheet where I must insert a column every time the user selects 2 values (found in Pricelists sheet).

So Basically whenever a user chooses the Quote LP, or the Sell on web Values from the cell dropdown, I must insert a column adjacent to the value. (The dropdown values are referred from another worksheet in the same workbook)

So for example if a user selects cell A1 and selects Sell on web from the dropdown, a column must appear between A and B. The column must read "List Price", in cell B1.

If the new list price column can have a "collapse" button in cell H5 that will cause the column to hide, that would be amazing as well.

Thank you and I apprecaite any and all the help!!
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.

Forum statistics

Threads
1,215,054
Messages
6,122,895
Members
449,097
Latest member
dbomb1414

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top