Results 1 to 2 of 2

Copy EntireRow within selected range to sheet + print

Threaded View

  1. #1
    Registered User
    Join Date
    08-15-2014
    Location
    Denmark
    MS-Off Ver
    365 Pro
    Posts
    94

    Copy EntireRow within selected range to sheet + print

    Hi all

    I am in need of a simple loop VBA that is able to copy the data of the entire row within the selected range one by one to another sheet AS TEXT within the workbook, then print a 3rd sheet that has simple "=" formulas to the 1:1 range in the sheet that the data is pasted into, then continue with the next entire row within the selected range.

    For example, if you take a look at the attached examplesheet, the functionality should be something like this:

    1. Select range in the sheet called "Maskinspecifikation", e.g. range E6:R10.
    2. Copy the entire row of 6:6 to row 1:1 in the sheet called "Forsidedatamatrix" as text (I guess it is important to paste as text, or the lookup formulas will break).
    3. PrintOut 3 copies of "Forsidedata".
    4. Loop will continue with next row of selection, being 7:7 and also paste it to 1:1.
    5. Loop ends when 10:10 has been printed.

    I tried making this with macro recording, but ended up with 440 lines of code, which I think could be done much more simple.

    Any help will be much appreciated

    EDIT: One more important thing to mention of course, is that if selection is outside of the table (Table3 in the workbook), then the code should give a MsgBox and end sub.
    Attached Files Attached Files
    Last edited by chriskay; 11-17-2022 at 06:55 AM.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Copy range from each selected cell and paste on next available row on new sheet
    By marcosis in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-26-2020, 08:35 PM
  2. [SOLVED] Copy range from user selected sheet of another file to original worksheet
    By bob101 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-07-2015, 09:54 AM
  3. Set print area of selected range then print preview if ok then print the document!
    By HaroonSid in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-01-2014, 07:10 AM
  4. Copy selected name range from one sheet to another
    By smothkid in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-26-2013, 08:19 AM
  5. [SOLVED] copy-paste-selected-cell-range-another-sheet
    By KK1234 in forum Excel Programming / VBA / Macros
    Replies: 18
    Last Post: 04-26-2013, 06:12 AM
  6. copy paste selected range from one sheet to another
    By sivdin in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-10-2011, 06:57 AM
  7. How do I edit a selected range then copy the range into an new sheet???
    By dwyborn in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-16-2005, 12:11 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