+ Reply to Thread
Results 1 to 9 of 9

fast macro to export table (not range) from file to another in the same folder

  1. #1
    Forum Contributor
    Join Date
    05-08-2021
    Location
    ALQUDS
    MS-Off Ver
    2019
    Posts
    210

    fast macro to export table (not range) from file to another in the same folder

    Hi Guys
    I search for way to my project to export table name "TABLE1" from open file in RESULT sheet to closed file in sheet TABLE
    two both files are existed in this directory "C:\Users\Hasson-PC\Downloads\REPORT"
    when export to close file should not be open after run the macro and every time run the macro should replace data in TABLE sheet for closed file
    thanks

  2. #2
    Forum Expert
    Join Date
    11-24-2013
    Location
    Paris, France
    MS-Off Ver
    Excel 2003 / 2010
    Posts
    9,831

    Question Re: fast macro to export table (not range) from file to another in the same folder


    Hi,

    why do not use the classic VBA Copy method ? …

  3. #3
    Forum Expert
    Join Date
    10-06-2017
    Location
    drevni ruchadlo
    MS-Off Ver
    old
    Posts
    2,151

    Re: fast macro to export table (not range) from file to another in the same folder

    Quote Originally Posted by Hasson View Post
    ... to export ... from open file ... to closed file ...
    There is no such thing as "export"/"writing" to a "closed file".
    Each file on the disk, in order to read or write something from it, must be opened in the appropriate mode (with the appropriate data structure defined by the program that supports it).
    The fact that sometimes you can't see that the file has been opened is only due to the fact that the given mechanism for accessing the file does not launch the appropriate graphical interface for it.

  4. #4
    Forum Contributor
    Join Date
    05-08-2021
    Location
    ALQUDS
    MS-Off Ver
    2019
    Posts
    210

    Re: fast macro to export table (not range) from file to another in the same folder

    why do not use the classic VBA Copy method ? …
    if I have idea I don't post here .

  5. #5
    Forum Contributor
    Join Date
    05-08-2021
    Location
    ALQUDS
    MS-Off Ver
    2019
    Posts
    210

    Re: fast macro to export table (not range) from file to another in the same folder

    Each file on the disk, in order to read or write something from it, must be opened in the appropriate mode (with the appropriate data structure defined by the program that supports it).
    The fact that sometimes you can't see that the file has been opened is only due to the fact that the given mechanism for accessing the file does not launch the appropriate graphical interface for it.
    Thanks for this clarification !
    I know it , just I wanted confirmation (no need keeping opened file after export data).

  6. #6
    Valued Forum Contributor
    Join Date
    08-08-2022
    Location
    Buenos Aires
    MS-Off Ver
    Excel 2019
    Posts
    1,777

    Re: fast macro to export table (not range) from file to another in the same folder

    Quote Originally Posted by Hasson View Post
    Hi Guys
    I search for way to my project to export table name "TABLE1" from open file in RESULT sheet to closed file in sheet TABLE
    two both files are existed in this directory "C:\Users\Hasson-PC\Downloads\REPORT"
    when export to close file should not be open after run the macro and every time run the macro should replace data in TABLE sheet for closed file
    thanks
    Hello, Hasson, Try with:

    Please Login or Register  to view this content.
    Last edited by beyond Excel; 05-01-2023 at 08:43 AM.
    You are always very welcome if you add reputation by clicking the * (bottom left) of each message that has helped you.

  7. #7
    Forum Expert
    Join Date
    10-06-2017
    Location
    drevni ruchadlo
    MS-Off Ver
    old
    Posts
    2,151

    Re: fast macro to export table (not range) from file to another in the same folder

    Please Login or Register  to view this content.

  8. #8
    Forum Contributor
    Join Date
    05-08-2021
    Location
    ALQUDS
    MS-Off Ver
    2019
    Posts
    210

    Re: fast macro to export table (not range) from file to another in the same folder

    thanks guys !
    this is exactly what I want it .

  9. #9
    Valued Forum Contributor
    Join Date
    08-08-2022
    Location
    Buenos Aires
    MS-Off Ver
    Excel 2019
    Posts
    1,777

    Re: fast macro to export table (not range) from file to another in the same folder

    .
    I'm glad that's the case and thanks for the +Rep.

+ 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] Macro to export specific columns to txt file from expanding range
    By naira in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-28-2019, 05:17 PM
  2. Export tabs as one file to folder
    By Pi* in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 01-15-2017, 12:22 AM
  3. [SOLVED] To create a file folder in the current workbook location and export the file
    By Ravana in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-10-2016, 07:30 AM
  4. Macro to export specific range of data to text file for each worksheet
    By sonofamonkey10 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-30-2013, 05:43 PM
  5. [SOLVED] Macro to export range of cells to notepad file.
    By MrIdontknowexcel in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-28-2012, 03:17 PM
  6. [SOLVED] macro to export a range to a text file?
    By [email protected] in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-21-2006, 09:30 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