+ Reply to Thread
Results 1 to 3 of 3

Google Sheets Duplicate Nth Character and/or Vowel in a string.

  1. #1
    Registered User
    Join Date
    04-23-2007
    Posts
    34

    Google Sheets Duplicate Nth Character and/or Vowel in a string.

    Hi, I'm wondering if it's possible with a formula to duplicate one of the characters in a string, or to duplicate the first or last vowel.

    Using the word Burger as an example.

    If I wanted to duplicate the first character, my new cell value would be Bburger.

    If I wanted to duplicate the fourth character, my new cell value would be Burgger.

    If I wanted to duplicate the first vowel, my new cell value would be Buurger.

    If I wanted to duplicate the last vowel, my new cell value would be Burgeer.

    And so on...


    I have found several resources regarding replace and substitute, but nothing this specific.

    Thanks in advance for any responses.

  2. #2
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,425

    Re: Google Sheets Duplicate Nth Character and/or Vowel in a string.

    With the word Burger in A1 put the following into B1: =LEFT(A1,1)&LOWER(A1)
    With the word Burger in A2 put the following into B2: =LEFT(A2,3)&MID(A2,4,1)&RIGHT(A2,LEN(A2)-3)
    With the word Burger in A3 put the following into B3:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    With the word Burger in A4 put the following into B4:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    For google you may have to use array formulas for B3:B4
    B3:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    B4:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Let us know if you have any questions.
    Last edited by JeteMc; 01-10-2022 at 11:42 AM. Reason: Added array entered formulas
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

  3. #3
    Forum Expert rorya's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365 Ent SAC
    Posts
    8,885

    Re: Google Sheets Duplicate Nth Character and/or Vowel in a string.

    For the generic character replacement, assuming text in a1 and the number of the character in B1, you can use:

    =PROPER(REPLACE(A1,B1,1,REPT(MID(A1,B1,1),2)))
    Rory

+ 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. Substitute final vowel of text string
    By Henry54289 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 12-28-2020, 06:10 AM
  2. Replies: 9
    Last Post: 01-23-2018, 02:52 PM
  3. replace EACH Nth occurrence a character in a string with another character
    By mattman7 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 06-23-2016, 12:23 PM
  4. Macro to search a string ending with vowel "AEIOUY"
    By kitunga in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-02-2014, 02:37 PM
  5. [SOLVED] find the character position in a string of the last occurrence of a nominated character
    By jmac1947 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-04-2014, 11:52 PM
  6. match duplicate string character
    By subhas in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 12-26-2009, 02:12 AM
  7. [SOLVED] Function to return Character Position of Xth character within a string
    By Andibevan in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-09-2005, 11:05 AM

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