Consulting

Results 1 to 5 of 5

Thread: Solved: Print Selected Cells to Another Cell

  1. #1

    Question Solved: Print Selected Cells to Another Cell

    I'm trying to print data from sheet1. row.cells selected to sheets.cells
    But I don't know how to do
    I tried to make this but didn't accept
    Dim cel as Cells

    [VBA]For i as Integer= sheets(1).Cells.Rows.Count -1
    set Cel= Sheets(1).Cells(i,1).Cells.Value
    Sheets(1).Cells.Value = cel.Select [/VBA]

  2. #2
    Administrator
    VP-Knowledge Base
    VBAX Grand Master mdmackillop's Avatar
    Joined
    May 2004
    Location
    Scotland
    Posts
    14,489
    Location
    You need to be a lot clearer in your request.
    MVP (Excel 2008-2010)

    Post a workbook with sample data and layout if you want a quicker solution.


    To help indent your macros try Smart Indent

    Please remember to mark threads 'Solved'

  3. #3
    I have four rows include each one have cells.
    When I select these rows with cells I want to print each cell to another cell in another sheet.
    I hope I'm clear

  4. #4
    Administrator
    VP-Knowledge Base VBAX Grand Master mdmackillop's Avatar
    Joined
    May 2004
    Location
    Scotland
    Posts
    14,489
    Location
    Try this
    [VBA]Sub CopyCells()
    Selection.EntireRow.Copy Sheets(2).Cells(Rows.Count, 1).End(xlUp)(2)
    End Sub
    [/VBA]
    MVP (Excel 2008-2010)

    Post a workbook with sample data and layout if you want a quicker solution.


    To help indent your macros try Smart Indent

    Please remember to mark threads 'Solved'

  5. #5
    Thank you for help!!!

Posting Permissions

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