Results 1 to 2 of 2

Thread: Autofill Text if Criteria are met

  1. #1
    Member
    Join Date
    Jun 2012
    Posts
    80
    Rep Power
    13

    Question Autofill Text if Criteria are met

    Hi,

    I would like a solution (preferably a VBA) to an autofill problem.

    I have attached a sample report showing the Data and the Result expected.

    I would like the name of the Salesman to appear under column A, ONLY when there is data present in column B to F.

    Autofill.xlsx

    Regards,
    Siyab

  2. #2
    Fuhrer, Vierte Reich DocAElstein's Avatar
    Join Date
    Aug 2014
    Posts
    9,458
    Rep Power
    10
    Hi Siyab,
    This sort of requirement I usually do in VBA with some sort of
    __Do While
    ___ ' do things while certain conditions are met.
    __Loop

    Type coding.
    We are basically needing to do things while certain conditions are met.



    So…
    This is the sort of thing you had:
    Row\Col A B
    1 Sales Analysis Report
    2
    3 Sales Employee Area
    4
    5 John Smith
    6 Las Vegas
    7
    8 Las Vegas total
    9
    10 Texas
    11
    12 Texas total
    13
    14 John Smith total
    15
    16 Donald Trump
    17 New York
    18 New York
    19
    20 New York total


    If you run this macro here: https://excelfox.com/forum/showthrea...ll=1#post15704 on that data, then you should get something like this:

    Row\Col A B
    1 Sales Analysis Report
    2
    3 Sales Employee Area
    4
    5 John Smith
    6 John Smith Las Vegas
    7
    8 Las Vegas total
    9
    10 John Smith Texas
    11
    12 Texas total
    13
    14 John Smith total
    15
    16 Donald Trump
    17 Donald Trump New York
    18 Donald Trump New York
    19
    20 New York total




    Alan
    Last edited by DocAElstein; 10-20-2021 at 08:16 PM.
    A Folk, A Forum, A Fuhrer ….

Similar Threads

  1. Autofill and Reverse Autofill
    By Anshu in forum Excel Help
    Replies: 5
    Last Post: 08-15-2020, 10:55 PM
  2. AutoFill Formula To The Last Row With Data
    By SaburaZera in forum Excel Help
    Replies: 2
    Last Post: 08-22-2014, 11:54 AM
  3. Need an Autofill VBA
    By mrprofit in forum Excel Help
    Replies: 12
    Last Post: 05-19-2014, 07:45 PM
  4. Insert Value When A Conditin is Met
    By Ajit in forum Excel Help
    Replies: 3
    Last Post: 09-12-2013, 06:58 PM
  5. Replies: 11
    Last Post: 04-07-2013, 07:51 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •