+ Reply to Thread
Results 1 to 3 of 3

point to local folder to import from text

  1. #1
    Registered User
    Join Date
    03-13-2012
    Location
    Stafford, England
    MS-Off Ver
    Excel 2007
    Posts
    87

    point to local folder to import from text

    Good afternoon,

    I am having difficulty pointing to the local patch when importing from text; hopefully someone will be kind enough to point me in the right direction.

    I need the local folder along with the file name being pulled from a cell in excel.

    This is what works when I put the file path in

    Please Login or Register  to view this content.
    This is where I am at, I think I'm just getting the quote marks messed up

    Please Login or Register  to view this content.
    Now when I try the second option I get the debugger pointing at the last line ....Refresh

    Please Login or Register  to view this content.
    Oh, before this part I have a macro to clear the contents of the cell and remove the last connection. I don't think that this will affect the rest of the code, but I will include it anyway.


    Please Login or Register  to view this content.

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: point to local folder to import from text

    Hello kenny.fsw,

    You were correct about the quotes not being in the right places. Here is the corrected code...

    Please Login or Register  to view this content.
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Registered User
    Join Date
    03-13-2012
    Location
    Stafford, England
    MS-Off Ver
    Excel 2007
    Posts
    87

    Re: point to local folder to import from text

    Thank you Leith,

    I now understand how the quote marks work there.

+ 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. Auto import data from all text files in a folder (VBA)
    By anto80mtl in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-14-2013, 12:34 PM
  2. Replies: 0
    Last Post: 08-10-2012, 02:32 AM
  3. How to import all text files (column wise) from a folder?
    By Amit1 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-27-2012, 02:25 AM
  4. [SOLVED] Import text file from specific folder
    By Ricker090 in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 07-07-2012, 09:08 PM
  5. import all text files in folder
    By shoshanako in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-22-2008, 10:01 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