Need to paste to a specific cell Macro

bryanalmeida525

New Member
Joined
Dec 12, 2017
Messages
12
Sub Steps()


Dim col(1 To 2) As Variant
Dim arr() As Variant
Dim x As Long
Dim LR As Long

col(1) = 2
col(2) = 16

Application.ScreenUpdating = False
For i = 1 To 2

For x = 1 To 2
With Sheets("Amir")
LR = .Cells(.Rows.Count, col(x)).End(xlUp).Row - 1
arr = .Cells(3, col(x)).Resize(LR).Value
End With
Sheets("Entry").Cells(Rows.Count, 1).End(xlUp).Resize(UBound(arr, 1)).Value = arr

Erase arr

Next x
Next i

Sheets("Entry").Range("A:A").SpecialCells(xlCellTypeBlanks).Delete shift:=xlUp

Application.ScreenUpdating = True

Erase col

End Sub



I need line:


Sheets("Entry").Cells(Rows.Count, 1).End(xlUp).Resize(UBound(arr, 1)).Value = arr


to paste starting at (A7) without ruining the Ubound and the rest of the formula.
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
I need line:

Sheets("Entry").Cells(Rows.Count, 1).End(xlUp).Resize(UBound(arr, 1)).Value = arr

to paste starting at (A7) without ruining the Ubound and the rest of the formula.
Replace Cells(Rows.Count, 1).End(xlUp) with Range("A7")...

Sheets("Entry").Range("A7").Resize(UBound(arr, 1)).Value = arr
 
Upvote 0

Forum statistics

Threads
1,215,995
Messages
6,128,180
Members
449,430
Latest member
sadielynn7

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