Merge and Unmerge Cells

Bluwara

New Member
Joined
Nov 7, 2017
Messages
27
Morning all,

I want to know the vba code to merge and unmerge cells. The following table is the information I have.


<tbody>
</tbody>
Dropdown List

Code Name
Code No
Code Rate
Total Amount
Drop Down List
AB | 02 | 0.10%
AC | 05 | 0.013%

AF | 15
BR | 65

<tbody>
</tbody>


Merge option

Merge option

Unmerge option
Unmerge option



As you can see from the table, There is 1 drop down menu that has 2 different selection options. One is the merge option and the other is the unmerge option.

When I input a value from another cell, it triggers one of the 2 (merge or unmerge) options to show on the drop down list. This part I have done.

What I am trying to achieve is when the merged option is selected and when I pick an item from the drop down list, row cell from Code Name/Code No/Code Rate all merge. And then auto move on to the next row to fill another row with the next merge selection.

Likewise to the unmerge option, when I select an item from the drop down list the Code Name/Code No/Code Rate will be filled in from their drop down lists.

Hope this is clear and thanks in advance.


Bluwara
 

Excel Facts

Last used cell?
Press Ctrl+End to move to what Excel thinks is the last used cell.

Forum statistics

Threads
1,215,200
Messages
6,123,612
Members
449,109
Latest member
Sebas8956

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