J
Joe
Hi Experts,
I'm copying values from one sheet and pasting onto other sheet. In the cells
that I'm copying, there are cells with no values, however while pasting I
want to replace blank cells with 0.
My sample code which copies and pastes the values is as below:
For example, Column A has few blanks cells. I want to substitute blank cells
with 0.
*****************
Sub CopyValues()
Dim NewSet As String
Dim NewSet1 As String
Dim NewSet2 As String
Dim NewSet3 As String
Dim NewSet4 As String
Dim NewSet5 As String
Dim CurLocation As String
CurLocation = ActiveCell.Address
Sheets("Source").Select
Columns("A:G").Select
Application.CutCopyMode = False
Selection.Copy
Sheets("Target").Select
Columns("A:G").Select
ActiveSheet.Paste
End Sub
************************
I'm copying values from one sheet and pasting onto other sheet. In the cells
that I'm copying, there are cells with no values, however while pasting I
want to replace blank cells with 0.
My sample code which copies and pastes the values is as below:
For example, Column A has few blanks cells. I want to substitute blank cells
with 0.
*****************
Sub CopyValues()
Dim NewSet As String
Dim NewSet1 As String
Dim NewSet2 As String
Dim NewSet3 As String
Dim NewSet4 As String
Dim NewSet5 As String
Dim CurLocation As String
CurLocation = ActiveCell.Address
Sheets("Source").Select
Columns("A:G").Select
Application.CutCopyMode = False
Selection.Copy
Sheets("Target").Select
Columns("A:G").Select
ActiveSheet.Paste
End Sub
************************