+ Reply to Thread
Results 1 to 12 of 12

Duplicate List & Replace Placeholders

  1. #1
    Registered User
    Join Date
    08-27-2006
    Posts
    48

    Duplicate List & Replace Placeholders

    Hi,

    I am writing text ads for paid search. There are three columns (headline 1, headline 2, and description). I have attached a sample.

    Some of these cells contain text and placeholders. I have a list of brands I want to replace the placeholders with.

    Right now I make a copy of all the ads, then manually find + replace with each brand. That's fine for a couple, but now we are talking about 80+ brands.

    Looking at the example, I would like to be able to find a way for Excel to take the list of ads, create a second copy, and replace the placeholder [designer] with the list of brand 1, brand 2, and brand 3.

    Any ideas would be greatly appreciated.
    Attached Files Attached Files

  2. #2
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,223

    Re: Duplicate List & Replace Placeholders

    As per data sheet idea not clear. can you enter before data and after required result data, its more clearity.


    atul


    If my answer (or that of other members) has helped you, please say "Thanks" by clicking the Add Reputation button at the foot of one of their posts.

    Also: if your problem is solved, please take the time to mark your thread as SOLVED by going to the top of your first post, selecting "Thread Tools" and then "Mark thread as solved".

  3. #3
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Duplicate List & Replace Placeholders

    maybe this one
    H2: =SUBSTITUTE(A2,"[designer]",$F2)
    drag to the right and down

  4. #4
    Registered User
    Join Date
    08-27-2006
    Posts
    48

    Re: Duplicate List & Replace Placeholders

    Sure. The new version is attached. The orange is the before. The green is after. I underlined what is changed between the two. Also, though column B does not show a change, there could be ads where it may have a placeholder as well.

    In case it needs clarification, all three cells in a row are part of the same ad.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    08-27-2006
    Posts
    48

    Re: Duplicate List & Replace Placeholders

    Thanks. I thought about that. The problem is a brand value doesn't substitute every ad. The ads listed are two different ads. So I get Brand 1 in the first ad, but not in the second ad. Vice versa with Brand 2. I would still need to replicate all the ads by however many brands I have. So if I have 80 brands, then I would need 80 groups of those 2 ads in the sample file.

    That is unless there is a way for a formula (as you drag it) to count the rows above the current row where "brand 1" appears and when it calculates 2, then it would copy the first ad again and replace it would brand 2. Then when brand 2 shows 2 ads, it would replace it would brand 3, etc.

    That probably made things more confusing. Haha.

    Though, replicating the brands and the ads 80 times, then substituting is better than the way I am currently doing it. So we are moving in the right direction.

    Per the request of poster AVK, I uploaded another version of the spreadsheet to show what it should look like. The blank row between the results are not necessary. I just put it in there. The green is the after an you picked up on what what needed to replaced.
    Last edited by seethesun; 05-23-2017 at 03:57 PM.

  6. #6
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Duplicate List & Replace Placeholders

    check this, maybe it will work for you
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    adjust references accordingly

    see att.
    Attached Files Attached Files

  7. #7
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,206

    Re: Duplicate List & Replace Placeholders

    Try

    Sheet1 has named range "Brand_List"

    in Sheet2

    in A2

    =IFERROR(SUBSTITUTE(INDEX(Sheet1!A$2:A$100,MOD(ROWS($1:1)-1,COUNTIF(Sheet1!A$2:A$100,"?*"))+1),"[designer]",INDEX(Brand_list,INT((ROWS($1:1)-1)/COUNTIF(Sheet1!A$2:A$100,"?*"))+1)),"")

    Copy across and down
    Attached Files Attached Files

  8. #8
    Registered User
    Join Date
    08-27-2006
    Posts
    48

    Re: Duplicate List & Replace Placeholders

    Thanks!

    That seems to work. Now, I am trying to figure out how to alter the formula to replace additional placeholders. I only had one yesterday when I posted this, but I have since written more and have a total of 3 different placeholders that could be in any given ad.

    [designer]
    [product]
    [gender]

  9. #9
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,206

    Re: Duplicate List & Replace Placeholders

    Why did you not post a file with these in the first place?

    Post a FINAL file please.

  10. #10
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Duplicate List & Replace Placeholders

    I can say only: LOL

  11. #11
    Registered User
    Join Date
    08-27-2006
    Posts
    48

    Re: Duplicate List & Replace Placeholders

    I figured it out.

    And I didn't post them in the first place, because they didn't exist. As I mentioned in the previous post, it wasn't until I decided to write more (this morning) that I realized I needed them.

  12. #12
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,206

    Re: Duplicate List & Replace Placeholders

    OK: well done.

    The additions should follow the same pattern as the "Designer" placeholders.

+ 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. [SOLVED] Code to check cell against a list for duplicate, if no duplicate, post to bottom of list..
    By wannabacat in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-28-2015, 11:42 AM
  2. Format Placeholders in Word
    By kiwicantfly in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-22-2014, 06:17 AM
  3. Replies: 1
    Last Post: 01-26-2012, 10:06 AM
  4. Sorting numbers with different placeholders.
    By whitekerj in forum Excel General
    Replies: 1
    Last Post: 02-08-2007, 05:08 PM
  5. placeholders
    By jhahes in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-01-2006, 10:31 AM
  6. SUMPRODUCT with PLACEHOLDERS?
    By titushanke in forum Excel General
    Replies: 5
    Last Post: 03-06-2006, 09:20 AM
  7. [SOLVED] Zero Placeholders in number cell
    By B. Parizo in forum Excel General
    Replies: 3
    Last Post: 09-15-2005, 09:05 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