Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Merge Cells with excel 2003
Hello,
I have a worksheet that I would like to merge 2 cells each row (200 rows and several worksheets) begining with A6:B6. Below is a code I've tried to modify but I still can't get it to work right. Can this code be changed to merge 2 cells begining with A6:B6 through 200 rows? Sub TryNow2() Dim i As Integer For i = 0 To 2 Cells(6, i * 1 + 1).Resize(1, 2).Merge Next i End Sub Thanks for your help in advance, jfcby |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Merge Cells with excel 2003
Your code as written will walk through the columns not the rows. Your
counter should be in the first part of the parenth, i.e. For i = 0 To 194 Cells(i*1+6,1) "jfcby" wrote: Hello, I have a worksheet that I would like to merge 2 cells each row (200 rows and several worksheets) begining with A6:B6. Below is a code I've tried to modify but I still can't get it to work right. Can this code be changed to merge 2 cells begining with A6:B6 through 200 rows? Sub TryNow2() Dim i As Integer For i = 0 To 2 Cells(6, i * 1 + 1).Resize(1, 2).Merge Next i End Sub Thanks for your help in advance, jfcby |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Merge Cells with excel 2003
Thank you JLGWhiz the code modification works great!!!!
jfcby JLGWhiz wrote: Your code as written will walk through the columns not the rows. Your counter should be in the first part of the parenth, i.e. For i = 0 To 194 Cells(i*1+6,1) "jfcby" wrote: Hello, I have a worksheet that I would like to merge 2 cells each row (200 rows and several worksheets) begining with A6:B6. Below is a code I've tried to modify but I still can't get it to work right. Can this code be changed to merge 2 cells begining with A6:B6 through 200 rows? Sub TryNow2() Dim i As Integer For i = 0 To 2 Cells(6, i * 1 + 1).Resize(1, 2).Merge Next i End Sub Thanks for your help in advance, jfcby |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
how to delete and insert in a two cells merge using Access 2003? | Excel Worksheet Functions | |||
excel 2003: mail merge issue | Excel Discussion (Misc queries) | |||
Need help with mail merge - excel 2003 to word 2003 please.. | Excel Discussion (Misc queries) | |||
Need to select 4 cells and merge them using Excell 2003 | Excel Programming | |||
Merge cells in Excel 2003 doesn't show up on Format Alignment | Excel Discussion (Misc queries) |