+ Reply to Thread
Results 1 to 6 of 6

Text File import program not functioning

  1. #1
    Registered User
    Join Date
    01-22-2010
    Location
    Sheffield
    MS-Off Ver
    Excel 2003
    Posts
    4

    Text File import program not functioning

    This code is from an edited macro & is designed to import a text file which is stored automatically with a date based name

    "Ext" reffers to pre defined file extention string, and the FileName string is made up of information from cells in the spreadsheet. I have tested this string and it is producing the correct filename (I think!).

    The code will not function and I can't figure out why. When I debug, it highlights the final line " .Refresh BackgroundQuery:=False". Any fix or alternate code sugestions would be very welcome.

    Please Login or Register  to view this content.
    Last edited by Oliver H; 01-25-2010 at 05:29 AM.

  2. #2
    Forum Contributor Rick_Stanich's Avatar
    Join Date
    11-21-2005
    Location
    Ladson SC
    MS-Off Ver
    Office365
    Posts
    1,177

    Re: Text File import program

    Please read the forum rules.
    3. Use code tags around code. Posting code without them makes your code hard to read and difficult to be copied for testing. Highlight your code and click the # button at the top of the post window. If you are editing an existing post, press Go Advanced to see the # button. For more information about these and other tags, click here.
    http://www.excelforum.com/forum-rule...rum-rules.html
    Regards

    Rick
    Win10, Office 365

  3. #3
    Registered User
    Join Date
    01-22-2010
    Location
    Sheffield
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Text File import program

    Basically, I just want to import a text file to a worksheet and then delimit it by 'Space'. Anyone have a solution for this please?

  4. #4
    Registered User
    Join Date
    01-22-2010
    Location
    Sheffield
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Text File import program not functioning

    I have attached the xls 2003 file. Could someone please have a look at my codes. The file also contains a macro to return the full file path in order to check it's integrity.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    01-22-2010
    Location
    Sheffield
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Text File import program not functioning

    Please help. Noone is responding to my post... which is leaving me a little worried. Have I neglected to include some vital bit of information, or is this queiry simply too petty for your godly excel powers??

    Even if someone doesn't have an exact fix, if there are anny comments or suggestions as to where my problem may be, they would be helpful. If anyone has bypassed this, thinking that the solution is obvious, then please let me know what that solution is, or at least point me in the right direction.

    I'm feeling a little unwelcome....

    I have a feeling the problem is somewhere in the path name, an may be due to the fact that the file is on a networked drive.... Any suggestions??

  6. #6
    Forum Contributor Rick_Stanich's Avatar
    Join Date
    11-21-2005
    Location
    Ladson SC
    MS-Off Ver
    Office365
    Posts
    1,177

    Re: Text File import program not functioning

    1. Commnets such as this may make members look away.
    or is this queiry simply too petty for your godly excel powers??
    I'm feeling a little unwelcome
    2. Make sure the UNC path is "eaxctly" the same as it appears in a dialog box. CAPS are important. (I believe).
    "Ext" reffers to pre defined file extention string, and the FileName string is made up of information from cells in the spreadsheet. I have tested this string and it is producing the correct filename (I think!).
    3. Try removing the offending line temporarily?
    Please Login or Register  to view this content.
    Think about how your original question is stated it may be unclear to many what aid you need.

    Usually I find the path to be the problem, whether it is due to the string (CAPS, not caps, ParTiAL CaPS, or some portion of the path string may be wrong).
    Last edited by Rick_Stanich; 02-16-2010 at 04:59 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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