+ Reply to Thread
Results 1 to 4 of 4

Copy HTM Files from Closed Workbook and Copy to Active Workbook if Sheet Name=File Name

Hybrid View

  1. #1
    Registered User
    Join Date
    04-15-2015
    Location
    South Dakota
    MS-Off Ver
    Microsoft Office 2013
    Posts
    23

    Re: Copy HTM Files from Closed Workbook and Copy to Active Workbook if Sheet Name=File Nam

    I am looking to replace. My macro is lacking the connection from when it copies I need a way to take the objfile.name and if equal to tab/sheet name to paste into that tab. Any ideas? I tried to run this, but blacked out my excel.

    [Sub MyMacro(strDesiredWkb As String)
    For Each objFile In objFolder.Files
    If objFile.Name = Sheets(sheetname) Then
    ActiveSheet.Copy ThisWorkbook.Sheets(Sheets.Count)
    
        MsgBox strDesiredWkb
    
    End Sub]
    Last edited by L_Misty; 12-07-2017 at 05:17 PM.

+ 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] vba code to copy a specific sheet from a closed workbook to the active workbook
    By JEAN1972 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-01-2017, 03:09 AM
  2. [SOLVED] macro to copy specifc sheet in closed workbook to the active sheet
    By JEAN1972 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-07-2017, 09:53 AM
  3. [SOLVED] macro to copy active sheet to a closed workbook in a specified directory
    By JEAN1972 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-30-2017, 04:43 AM
  4. [SOLVED] vba copy specific sheet from closed workbook to active workbook
    By JEAN1972 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-12-2017, 01:33 PM
  5. [SOLVED] copy specific sheet from closed workbook to active workbook
    By JEAN1972 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-10-2017, 10:26 PM
  6. vba copy specific sheet from closed workbook to active workbook
    By JEAN1972 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-09-2017, 02:34 PM
  7. Run Macro in closed workbook and copy specific coloumn in active workbook
    By shiva_reshs in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-07-2013, 03:43 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