+ Reply to Thread
Results 1 to 4 of 4

Copy the value in a cell, X times to adjacent cells

  1. #1
    Registered User
    Join Date
    07-16-2013
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    2

    Copy the value in a cell, X times to adjacent cells

    I want to copy the value of a cell to adjacent cells, X times, with X being the variable. For example, say in A1 I had the value 10 (variable) and B1 (value) I had 100. I want a formula to copy the value of 100, 10 more times and place these in rows C1 thru L1 (so now you would see a row containing 11 100's). If the variable was changed to say, 5. Then you would see a row of 6 100's from B1 to G1. So the formula is simple to copy a value X number of places to the right. Hoping this can be done without macros, rather a formula I can place within the cells.
    Hope this can be done.
    Thanks in Advance
    Matt

  2. #2
    Forum Contributor
    Join Date
    07-24-2012
    Location
    Denver, CO
    MS-Off Ver
    365
    Posts
    230

    Re: Copy the value in a cell, X times to adjacent cells

    I can think of a way to do that with formulas, but only if you edit each cell from column B to L separately and then autofill down (there may be other ways). What I would do for C1 is write "=IF(A1>0, A1*B1, "")" then for D1 "=IF(A1>1, A1*B1, "")" and continue the pattern and then autofill down
    ~~LaffyAffy13~~

    If I have helped you solve your problem, please be sure to click at the bottom left of my post.

    Thanks.

  3. #3
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Copy the value in a cell, X times to adjacent cells

    try
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  4. #4
    Registered User
    Join Date
    07-16-2013
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Copy the value in a cell, X times to adjacent cells

    Martin and Laffy. This has saved me a bunch of time. Thanks very much for your help. Matt

+ 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: 2
    Last Post: 07-01-2013, 10:00 PM
  2. [SOLVED] Copy adjacent cells based on matched cell criteria
    By asdfwqefwe3 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-26-2013, 02:26 AM
  3. Find percentage of times two adjacent cells have the same data
    By jamie_bisson in forum Excel Formulas & Functions
    Replies: 14
    Last Post: 02-26-2013, 01:53 AM
  4. [SOLVED] What is the best way to examine cell and copy adjacent cells to another worksheet?
    By LMersch in forum Excel - New Users/Basics
    Replies: 4
    Last Post: 07-19-2012, 06:08 PM
  5. Select and copy cells based on adjacent cell
    By Zaeguzah in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-30-2010, 02:42 AM

Tags for this Thread

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