+ Reply to Thread
Results 1 to 2 of 2

Copy first row if only first row of data available

  1. #1
    Registered User
    Join Date
    02-29-2020
    Location
    Malaysia
    MS-Off Ver
    Office 365
    Posts
    63

    Copy first row if only first row of data available

    Hi,

    i have a workbook as a masterfile and want to open another workbook to copy the data and paste it to my masterfile.
    here's the problem if my data only have the first row and the second row onwards is empty data. my current VBA code will copy the empty data and will cause the error when i paste the empty data into my masterfile.

    what is the VBA code to copy only the first row if only the first row of data available? then copy the entire row if the data is more than 1 row. the data is only available from column A to column T.

    My current code is below. Hope can assist to correct my code below. Also please check my Application.ScreenUpdating's code is it in the correct sequence?

    Please Login or Register  to view this content.

  2. #2
    Registered User
    Join Date
    02-29-2020
    Location
    Malaysia
    MS-Off Ver
    Office 365
    Posts
    63

    Re: Copy first row if only first row of data available

    Hi Mod, can assist to delete this thread? I opened in the wrong section. thanks.

+ 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. [SOLVED] Code to copy data does not copy last row in source data
    By Howardc1001 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-29-2018, 05:09 AM
  2. Copy data from sheet1 column with dynamic date, and copy data to second sheet column
    By Renaliiii in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 05-25-2016, 04:44 PM
  3. Copy & paste input data to sheet, copy result back out
    By stuartsjg in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-30-2015, 05:25 PM
  4. Saving copy of data and then running macro on all active worksheets in saved copy?
    By Science87 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-09-2014, 11:56 AM
  5. [SOLVED] Copy data with 4 cell interval and copy range of data like vlookup with structured output
    By Daydreams in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 08-23-2013, 04:08 AM
  6. Enter data, copy formulas, copy values, paste data, delete data
    By alf40 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-15-2013, 07:23 PM
  7. Macro to copy Dyanmic lists then copy sheet and clear the original data
    By twiggywales in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-30-2012, 01:06 PM

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