+ Reply to Thread
Results 1 to 6 of 6

formula for Dashes between the text

  1. #1
    Forum Contributor
    Join Date
    12-23-2012
    Location
    Pakistan
    MS-Off Ver
    Microsoft office LTSC professional plus 2021 version 2403 (Build 17425.20176)
    Posts
    365

    formula for Dashes between the text

    Dear all,
    I need a formula which place dashes in the text as shown in the attachment.

    IT2021090901011166910
    the above must be like the below one
    IT-20210909-0101-1166910
    Attached Files Attached Files

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,985

    Re: formula for Dashes between the text

    This:

    =LEFT(A2,2)&"-"&MID(A2,3,8)&"-"&MID(A2,11,4)&"-"&MID(A2,15,8)

    AliGW on MS365 Insider (Windows) 64 bit

    A
    B
    1
    CPR No
    2
    IT2021061701011379530 IT-20210617-0101-1379530
    3
    IT2020031300551196951 IT-20200313-0055-1196951
    4
    IT2020031300551196951 IT-20200313-0055-1196951
    5
    IT2020031300551196951 IT-20200313-0055-1196951
    6
    IT2020061610561212126 IT-20200616-1056-1212126
    7
    IT2020100801011129701 IT-20201008-0101-1129701
    8
    IT2020100801011129703 IT-20201008-0101-1129703
    9
    IT2020111201011184670 IT-20201112-0101-1184670
    10
    IT2020111201011184670 IT-20201112-0101-1184670
    11
    IT2020111201011184670 IT-20201112-0101-1184670
    12
    IT2021031601011481393 IT-20210316-0101-1481393
    13
    IT2021031601011481393 IT-20210316-0101-1481393
    14
    IT2021031601011481393 IT-20210316-0101-1481393
    15
    IT2021041701011325038 IT-20210417-0101-1325038
    16
    IT2021052001011215010 IT-20210520-0101-1215010
    17
    IT2021052001011216958 IT-20210520-0101-1216958
    18
    IT2021061001011206037 IT-20210610-0101-1206037
    19
    IT2021063001011663713 IT-20210630-0101-1663713
    20
    IT2021080401011059222 IT-20210804-0101-1059222
    21
    IT2021090901011166932 IT-20210909-0101-1166932
    22
    IT2021090901011166910 IT-20210909-0101-1166910
    Sheet: Total Paid Amount
    Last edited by AliGW; 01-07-2022 at 07:01 AM.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Contributor
    Join Date
    12-23-2012
    Location
    Pakistan
    MS-Off Ver
    Microsoft office LTSC professional plus 2021 version 2403 (Build 17425.20176)
    Posts
    365

    Re: formula for Dashes between the text

    sorry it is working

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,985

    Re: formula for Dashes between the text



    That's what I've done ...

  5. #5
    Forum Contributor
    Join Date
    12-23-2012
    Location
    Pakistan
    MS-Off Ver
    Microsoft office LTSC professional plus 2021 version 2403 (Build 17425.20176)
    Posts
    365

    Re: formula for Dashes between the text

    Thank you very much

  6. #6
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,985

    Re: formula for Dashes between the text

    If you have not already done so, you may not be aware that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of all those who offered help.

+ 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. Replies: 3
    Last Post: 01-17-2014, 08:08 PM
  2. Want to add dashes to cell text...
    By bikersnm in forum Excel General
    Replies: 3
    Last Post: 05-11-2009, 03:00 PM
  3. Removing text and dashes CB-PC-150
    By jonasmacs in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 09-13-2008, 04:11 PM
  4. How do I separate a text value with dashes?
    By Ray A in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 09-06-2005, 09:05 PM
  5. How do I separate a text value with dashes?
    By Ray A in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 09-06-2005, 05:05 PM
  6. [SOLVED] How do I separate a text value with dashes?
    By Phil in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 12:05 PM
  7. How do I separate a text value with dashes?
    By Phil in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-06-2005, 11:05 AM
  8. [SOLVED] How do I separate a text value with dashes?
    By Ray A in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 09-06-2005, 06: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