Dynamic Creation of rows in Excel

  • Thread starter Thread starter vikrampn
  • Start date Start date
V

vikrampn

HellO everyone,
I never did any VBA coding and i am right now lost on where to
start. This is what i am trying to achieve

I have a field "Number of Products", based on the number of products, I
need to create that many products in my excel

Each product has

Product name
Product description
Product Photo
Number of Competitors
Competitor name
Compeitor description

If the user enters 5 int he Number of products, then my method/Function
should be able to generate that many products.

I will really really appreciate any comment, suggestions in achieving
this. I am not even sure, if this something easy to do .

Regards
Vikram
 
If I understand you correct

This will copy A1:A6 down with a blank line between each product

Sub test()
Dim pcount As Long
Dim a As Long
a = 1
myNum = Application.InputBox("Enter a number")
For pcount = 1 To myNum
Range("a1:a6").Copy Cells(a, 1)
a = a + 7
Next
End Sub
 
Back
Top