loop function
Amazing chart utilities from Jon Peltier
Thanks Thanks:  0
Likes Likes:  0
Results 1 to 5 of 5

Thread: loop function

  1. #1
    New Member
    Join Date
    Feb 2002
    Posts
    18
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

     
    Hi All! Cool new board!
    Not sure if loop function is what i need.....
    I wish to copy a row (A1:Z1) from sheet1! and paste to row (A1:Z1) sheet2!, then change row Sheet1!A1:Z1's contents (via a series of VLOOKUP's) and paste to Sheet2!A2:Z2, then A3:Z3, A4:Z4, etc......but always copying from the same row in Sheet1.
    Excuse my inability at communicating my problems! always the case!

    Cheers!
    Lucky


  2. #2
    Board Regular
    Join Date
    Mar 2002
    Location
    Brampton
    Posts
    328
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    I think that you did not mean "loop" function. Is not clear how you would like to handle the series of events you described. The initial input in Sheet1 is going to be changed manually changing the content of the cells by formula vlookup? And when are you going to change again this content?

  3. #3
    Board Regular
    Join Date
    Mar 2002
    Location
    Cincinnati, Ohio, USA
    Posts
    6,824
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Hi

    It sounds like you simply need to link sheet2 to sheet1????

    If so, goto sheet2 A:1
    Type =
    Click on the sheet1 tab and click on Cell A:1
    Click the little checkmark on your formula bar. Left hand side above col A,B, or C

    Now right click on sheet2 cell A:1
    Choose copy
    Select(highlight), by dragging mouse, the range of sheet2 A:1 to Z:?

    Now right click anywhere in the shaded selection and choose paste.

    Hope this is what you need?

    Tom

  4. #4

    Join Date
    Mar 2002
    Posts
    372
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    To copy the values in Sheet1 range A1:Z1 to the next available row in Sheet2 :-

    Sub Copy_Values
    Dim rw As Long
    rw = Sheets("Sheet2").UsedRange.Cells.SpecialCells(xlCellTypeLastCell).Row + 1
    Sheets("Sheet2").Cells(rw, 1).Resize(, 26) = Sheets("Sheet1").[A1:Z1].Value
    End Sub

    Note : If Sheet2 is blank, the data will be put in row 2.

  5. #5
    New Member
    Join Date
    Feb 2002
    Posts
    18
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

      
    Thank you C O Jones. that is exactly what I was after.
    May the luck be with you.

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

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

 

 
DMCA.com