How to merge and unmerge cells in EXCEL workbook?
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
29-11-22 12:21 PM
I want to delete H~I columns in workbook.
Some cells of H~I columns are merged with the cells in J~L columns.
If I select and delete the H~I columns, J~L columns are alse be deleted.
I think maybe I can unmerge the cells, delete H~I columns and then merge the cells again.
I'm now facing another problem that Business Object[MS Excel VBO] has no action that can do merging and unmerging.
So how can I set the robot the merge and unmerge cells in workbook?
regards!
Some cells of H~I columns are merged with the cells in J~L columns.
If I select and delete the H~I columns, J~L columns are alse be deleted.
I think maybe I can unmerge the cells, delete H~I columns and then merge the cells again.
I'm now facing another problem that Business Object[MS Excel VBO] has no action that can do merging and unmerging.
So how can I set the robot the merge and unmerge cells in workbook?
regards!
1 REPLY 1
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
29-11-22 02:20 PM
Hi
You need to create a custom code action to unmerge cells. I'm not sure if the latest version of excel vbo available on Blue prism has the action I think it has a merge action but maybe not a unmerge. I've provided the code below you need to create a new action in the excel vbo, add a code stage then add the following code:
Dim ws As Object
ws = GetWorksheet(Handle, Workbook, Worksheet)
ws.Activate()
ws.Range(Range).UnMerge
The inputs are Handle, Workbook and Worksheet. Hope this helps 🙂
You need to create a custom code action to unmerge cells. I'm not sure if the latest version of excel vbo available on Blue prism has the action I think it has a merge action but maybe not a unmerge. I've provided the code below you need to create a new action in the excel vbo, add a code stage then add the following code:
Dim ws As Object
ws = GetWorksheet(Handle, Workbook, Worksheet)
ws.Activate()
ws.Range(Range).UnMerge
The inputs are Handle, Workbook and Worksheet. Hope this helps 🙂
