+ Reply to Thread
Results 1 to 2 of 2

Macro Creates Unknown Data Connection

  1. #1
    Registered User
    Join Date
    06-30-2010
    Location
    Nashville, TN
    MS-Off Ver
    Excel 2010
    Posts
    12

    Macro Creates Unknown Data Connection

    I have the attached VBA code that is a macro that copies data from five sheets that each have an individual data connection to a SharePoint site into a sixth sheet called ROLLUP. For some reason, when the macro runs, it creates a new data connection and calls it American1 (the first sheet name with a 1 after it) and this new connection posts data into the Rollup sheet. The problem is that every time you run the macro, it leaves the copy and then makes another copy of this new data connection. So when you run the macro a second time, there is now an American, American1, and American2 data connection. The American connection is approrpiate as it is the connection for the American tab, but the American1 tab is no longer being used and now the American2 connection is pasting to the Rollup sheet. Am I missing something in my code?

    Macro Text.txt

  2. #2
    Registered User
    Join Date
    06-30-2010
    Location
    Nashville, TN
    MS-Off Ver
    Excel 2010
    Posts
    12

    Re: Macro Creates Unknown Data Connection

    The macro was copying an pasting the data in the first sheet from A1 to the last cell. Because the data connection for the first sheet was attached to A1, the copy and paste was also adding the data connection to the Rollup. I have repointed the Macro to copy from A2 to the last cell on the first sheet.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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