+ Reply to Thread
Results 1 to 1 of 1

copying column of numbers from rows to other rows

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    05-04-2015
    Location
    Atlanta GA
    MS-Off Ver
    2010
    Posts
    106

    copying column of numbers from rows to other rows

    I've created this basketball game in which, after the game is finished the team stats are copied to each team's stat sheet. From there I want to copy the Points column (cells Q6-Q17) down to cells beginning at (L31-L41) and continuing to the next column (m,n,o,p..) for each game played. The below listed code works fine an a soccer game I created, that's because I keep the copied numbers in the same rows (6-17). I can't get it to work when I change the rows down to 31-42.




    Sub PlayerStats()
    Dim game As String
    Dim stats(20, 21) As Variant
    
    game = Cells(29, 10)     'game number
    For Row = 6 To 17     'row of stats to copy
        stats(Row, col) = Cells(Row, col + 17)     'column of stats to copy
    Next Row
     
    GoSub add
        
    add: For Row = 31 To 42     
             Cells(Row, 11 + game) = stats(Row, col)
         Next Row
    
    End Sub
    Last edited by JBeaucaire; 05-11-2015 at 10:41 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 4
    Last Post: 05-16-2014, 04:52 PM
  2. Copying Rows Without Numbers Ascending
    By eitsfan in forum Excel General
    Replies: 6
    Last Post: 02-11-2014, 04:45 PM
  3. Copying Columns into rows..Each column has over 200 rows
    By gauraviift in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-02-2012, 04:19 PM
  4. [SOLVED] Split One Column at Delimiter While Copying Contents of Second Column to Populate New Rows
    By medailSacrosanct in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 08-01-2012, 11:37 AM
  5. Copying rows with any value in one column
    By CrystalNewb in forum Excel General
    Replies: 4
    Last Post: 10-24-2009, 06:47 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1