Intersect with row dynamically

Pho*_*nix 1 excel vba

I am trying to intersect a target range with some row, changing dynamically: I was using this :

If Not intersect ([1:7],target) Is Nothing Then
Run Code Online (Sandbox Code Playgroud)

And it works, but :

Dim n as Integer : n = 7
If Not intersect ([1:n],target) Is Nothing Then
Run Code Online (Sandbox Code Playgroud)

Returns Error 424

Sco*_*ner 5

[] does not allow variables you will need to spell it out:

Dim n as Integer : n = 7
If Not intersect (Range("1:" & n),target) Is Nothing Then  
Run Code Online (Sandbox Code Playgroud)