+ Reply to Thread
Results 1 to 3 of 3

Copying data from a master worksheet to a folder full of closed workbooks

  1. #1
    Registered User
    Join Date
    08-12-2015
    Location
    Geraldton Australia
    MS-Off Ver
    2010
    Posts
    21

    Copying data from a master worksheet to a folder full of closed workbooks

    Hi Guys
    I am fairly new to VBA and am trying to create a workbook that copies data from a master worksheet to a specific worksheet in a folder full of closed workbooks when I click a button. I am using the code in the attached notepad file to do this but I keep having an application or object defined error on this particular line,
    Please Login or Register  to view this content.
    . I am not sure what I have done wrong but I can bet it comes from my lack of understanding of VBA and understanding how the commands work. I would love any help anyone can give me on this. BTW I had to put the code in the attachment as it was setting off a sucuri firewall thing that probably protects against dodgy code or something but I have no idea what in my code would be setting it off and I could not post it any other way



    VBA Test Code.txt

  2. #2
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,861

    Re: Copying data from a master worksheet to a folder full of closed workbooks

    I assume that in this (obviously not working because Cells accepts row and col arguments) you want to copy 12 cells starting from row lngrow?
    then
    Please Login or Register  to view this content.
    would do the job
    Best Regards,

    Kaper

  3. #3
    Registered User
    Join Date
    08-12-2015
    Location
    Geraldton Australia
    MS-Off Ver
    2010
    Posts
    21

    Re: Copying data from a master worksheet to a folder full of closed workbooks

    Thanks for that Kaper
    That seems to work although something strange is happening when I run the command. I go to open my sheets that have been altered and they wont open although in my windows preview pane I can see that the data has changed. Is there something preventing them opening when they are changed? I tried restarting my computer and clearing excel process and even opening them in excel safe mode but nothing seems to work. Thank you so much for your help
    Unit Sheets Original code.xlsmUnit Sheets New Code.xlsmTest Sheets 01.xlsx

+ 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. Formula for Master worksheet to pull data from multiple closed workbooks...
    By Batman24 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 10-29-2014, 06:24 AM
  2. Copying data from multiple workbooks having multiple sheets into one master worksheet
    By Navya Ahuja in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-15-2014, 09:42 AM
  3. Replies: 5
    Last Post: 09-30-2014, 07:00 PM
  4. [SOLVED] Macro to list worksheet names of all closed workbooks in a specified folder
    By Chrispelletier in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 05-15-2014, 12:52 PM
  5. Copying all EXCEL workbooks in a Folder to one master workbook
    By HitTheEXCELerator in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-10-2013, 10:42 PM
  6. VBA: Copying data from closed workbooks
    By staffordalex in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-06-2008, 01:20 PM
  7. Copying data from closed Workbooks
    By danman1043 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-03-2008, 09:11 AM

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