+ Reply to Thread
Results 1 to 10 of 10

Importing File Name Into Header

  1. #1
    Registered User
    Join Date
    10-26-2013
    Location
    Muncie, IN
    MS-Off Ver
    Excel 2010
    Posts
    17

    Importing File Name Into Header

    Hello Everyone!

    Is it possible to import a file name into header? The catch is that the file name that I need is not the file name of the workbook I am in. I have seen ways it can be done but they bring the entire file path instead of just the file name. I would like to be able to use this method to point to file to grab name from.

    Please Login or Register  to view this content.
    Thank You.
    Last edited by mkelsay91; 10-29-2013 at 07:46 AM.

  2. #2
    Forum Contributor
    Join Date
    01-18-2013
    Location
    Prague, Czech rep.
    MS-Off Ver
    Excel 2003 - 2016
    Posts
    138

    Re: Importing File Name Into Header

    Hi,

    and where is the file you want to bring in, I mean, if its opened it might work, but if its not opened nor mentioned anywhere else I dont see much of a chance to get the name of the file without using the whole filepath

    best regards

    Soul

  3. #3
    Registered User
    Join Date
    10-26-2013
    Location
    Muncie, IN
    MS-Off Ver
    Excel 2010
    Posts
    17

    Re: Importing File Name Into Header

    I was planned on using this to point to the file to grab name from.

    Please Login or Register  to view this content.

  4. #4
    Forum Contributor
    Join Date
    01-18-2013
    Location
    Prague, Czech rep.
    MS-Off Ver
    Excel 2003 - 2016
    Posts
    138

    Re: Importing File Name Into Header

    So the file is actualy opened, so that one might work....Btw. rereading what you wrote at the first post IŽve missed on one thing, i thought that youŽre refering to the process where they actualy need the path to the file to address your issue, but rereading it again it seems like they are doing what you want just they have the path in the place where youŽd like to see only the path name, in that case I suggest a loop that removes all the / from the string and than only the last one remains

    EDIT: got some meeting now but IŽll provide a code for the loop afterwards (1-2 hours), ps just let me know if my last thought process is correct
    Last edited by SoulPrisoner; 10-29-2013 at 07:59 AM.

  5. #5
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Importing File Name Into Header

    you can get the name from the full path
    Please Login or Register  to view this content.
    for instance
    Josie

    if at first you don't succeed try doing it the way your wife told you to

  6. #6
    Registered User
    Join Date
    10-26-2013
    Location
    Muncie, IN
    MS-Off Ver
    Excel 2010
    Posts
    17

    Re: Importing File Name Into Header

    Yeah. So basically I import this data, into my spread sheet that has a macro.
    I have to import the File Name of where my I pulled that Data, into a the right header.
    So I would need to filter all this "C:\Users\Matt\Downloads" out. However I can't be that specific as this is used on multiply Computers and don't follow my exact directory.

    I hope I am not making this sound confusing.

  7. #7
    Registered User
    Join Date
    10-26-2013
    Location
    Muncie, IN
    MS-Off Ver
    Excel 2010
    Posts
    17

    Re: Importing File Name Into Header

    Do you know of how I can tell it to place pulled name into right header?

  8. #8
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Importing File Name Into Header

    add
    Please Login or Register  to view this content.

  9. #9
    Registered User
    Join Date
    10-26-2013
    Location
    Muncie, IN
    MS-Off Ver
    Excel 2010
    Posts
    17

    Re: Importing File Name Into Header

    Thank You! I will marked as Solved!

  10. #10
    Forum Contributor
    Join Date
    01-18-2013
    Location
    Prague, Czech rep.
    MS-Off Ver
    Excel 2003 - 2016
    Posts
    138

    Re: Importing File Name Into Header

    Hm, just came from the meeting and i can see that issue already solved, well, GJ

    cu

+ 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. Importing a data from a text file - user-defined file
    By DaveSev in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-01-2013, 07:02 PM
  2. [SOLVED] importing text file into excel file using macro
    By ananthbulusu in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-26-2013, 04:08 PM
  3. VBA code for importing data from external workbook(s) for a given header
    By Adsup01 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-15-2013, 01:06 PM
  4. [SOLVED] Importing multiple csv files, adding filename to each row and removing the header
    By Telving in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-25-2012, 12:59 PM
  5. [SOLVED] Importing text file, only option to edit existing file
    By smokey99 in forum Excel General
    Replies: 8
    Last Post: 04-26-2006, 04:08 PM

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