billyheanue
Board Regular
- Joined
- Jul 13, 2015
- Messages
- 109
Hi all, so I am trying to resize the selection to equal a number of rows and columns specified in cells C45 and C46, respectively. My code gives me a 1004 Object Orientated error. Does anyone know how to fix this?
Sub TableExpand()
Worksheets("Sheet1").Activate
numrows = Selection.Rows.Count
numColumns = Selection.Columns.Count
Selection.resize(numrows = "C45", numColumns = "C46").Select
End Sub
I know there are probably a million things wrong with this, and if anyone has any help, it would be greatly appreiciated!
Thanks!
Bill from Mass
Sub TableExpand()
Worksheets("Sheet1").Activate
numrows = Selection.Rows.Count
numColumns = Selection.Columns.Count
Selection.resize(numrows = "C45", numColumns = "C46").Select
End Sub
I know there are probably a million things wrong with this, and if anyone has any help, it would be greatly appreiciated!
Thanks!
Bill from Mass