0

I have got this statement of code

Range("A"&Number :"W" & Number).Copy

Where Number is a digit representing the row. But this particular range doesn't seem to work well. I get a compile error and i don't know how to fix the Range to include a variable that increments the row number

Any help on that would be appreciated.

0

2 Answers 2

3

Try this

Range("A" & Number & ":W" & Number).Copy
Sign up to request clarification or add additional context in comments.

Comments

0

Here's another way

Const COLW As Long = 23

Cells(Number,1).Resize(1,COLW).Copy

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.