+ Reply to Thread
Results 1 to 7 of 7

VBA insert text cell for multiple file!!!

  1. #1
    Registered User
    Join Date
    03-22-2020
    Location
    HCM, Viet Nam
    MS-Off Ver
    2013
    Posts
    7

    VBA insert text cell for multiple file!!!

    Hi all,

    First time to the board, help me!!!
    In this case only a file. If multiple file excel (file1.xls, file2.xls,...filen.xls) i want insert text cell C1 with text: List
    Please Login or Register  to view this content.
    Last edited by alansidman; 03-23-2020 at 10:28 PM.

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,882

    Re: Help VBA insert text cell for multiple file!!!

    Code Tags Added
    Your post does not comply with Rule 2 of our Forum RULES. Use code tags around code.

    Posting code between [CODE]Please [url=https://www.excelforum.com/login.php]Login or Register [/url] to view this content.[/CODE] tags makes your code much easier to read and copy for testing, it also maintains VBA formatting.

    Highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found at http://www.excelforum.com/forum-rule...rum-rules.html



    (I have added them for you today. Please take a few minutes to read all Forum Rules and comply in the future.)
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  3. #3
    Registered User
    Join Date
    03-22-2020
    Location
    HCM, Viet Nam
    MS-Off Ver
    2013
    Posts
    7

    Re: Help VBA insert text cell for multiple file!!!

    yes, thanks ad!!!

  4. #4
    Forum Expert
    Join Date
    10-06-2008
    Location
    Canada
    MS-Off Ver
    2007 / 2013
    Posts
    5,525

    Re: Help VBA insert text cell for multiple file!!!

    Do you want to enter the word "List" in cell C1 in all sheets of all workbooks in a folder?
    In your snippet of code it looks like you want to add "Score: " to all cells in Range("B2:E9")
    But it does not specify in which sheets.

  5. #5
    Registered User
    Join Date
    03-22-2020
    Location
    HCM, Viet Nam
    MS-Off Ver
    2013
    Posts
    7

    Re: Help VBA insert text cell for multiple file!!!

    Yes, i want enter the word "List" in cell C1 in all sheets of all workbooks in a folder.
    Please Login or Register  to view this content.

  6. #6
    Forum Expert
    Join Date
    10-06-2008
    Location
    Canada
    MS-Off Ver
    2007 / 2013
    Posts
    5,525

    Re: Help VBA insert text cell for multiple file!!!

    So what is it. Replace whatever is in cell C1 with the word "List" or add the word "List " in front of whatever is in cell C1 already?
    The first scenario would just have "List" in cell C1.
    The second scenario would have, if you have for instance "Hello" in cell C1, "List Hello" as the end result in cell C1.

  7. #7
    Forum Expert
    Join Date
    10-06-2008
    Location
    Canada
    MS-Off Ver
    2007 / 2013
    Posts
    5,525

    Re: VBA insert text cell for multiple file!!!

    Try on a copy of your folder, and rename accordingly in the code, with your files.
    Please Login or Register  to view this content.

+ 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. open multiple file text and insert the data to sql server
    By lullabbyice in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-05-2016, 11:11 PM
  2. VBA code to insert data from multiple .txt files into one output file template file
    By psmith33 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-04-2015, 02:49 PM
  3. [SOLVED] insert multiple text box into one single cell
    By elizevonne in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 01-25-2015, 08:10 AM
  4. Macro that will insert a simple text string in top cell of text file
    By Davek11 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-25-2014, 07:31 PM
  5. Replies: 2
    Last Post: 08-16-2013, 02:45 AM
  6. Replies: 3
    Last Post: 06-25-2013, 04:41 AM
  7. Insert multiple picture file in excel with vba. File attached
    By junkyman98 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-11-2012, 10:51 AM

Tags for this Thread

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