+ Reply to Thread
Results 1 to 13 of 13

Serial number with bracket and space genaration for the given input by formula

  1. #1
    Forum Contributor
    Join Date
    02-15-2016
    Location
    India
    MS-Off Ver
    2016
    Posts
    671

    Serial number with bracket and space genaration for the given input by formula

    Hello Friends

    From 2 to 20 according to the input serial numbers with bracket and space should be generated by formula.

    Thanks in advance
    Attached Files Attached Files
    Sekar

  2. #2
    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
    30,879

    Re: Serial number with bracket and space genaration for the given input by formula

    Why must you have the results in one cell?

  3. #3
    Forum Contributor
    Join Date
    02-15-2016
    Location
    India
    MS-Off Ver
    2016
    Posts
    671

    Re: Serial number with bracket and space genaration for the given input by formula

    John, I could not able to understand this question `Why must you have the results in one cell?'.

    This is because in 1 cell requirement will vary form 1 to 20. So by using input cell and by formula need to populate the required serial numbers.

  4. #4
    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
    30,879

    Re: Serial number with bracket and space genaration for the given input by formula

    Why can you not have serial numbers on 5 or 13 consecutive rows?

    I always find it difficult to understand this need to "compress" the output to a single cell when you have 1 Million + rows!

  5. #5
    Forum Contributor
    Join Date
    02-15-2016
    Location
    India
    MS-Off Ver
    2016
    Posts
    671

    Re: Serial number with bracket and space genaration for the given input by formula

    This is because for the specific parameters sometimes we will get the 3 inputs sometimes it may be 7 it will very time to time. So if we can able to customize by using input number it will be fine.

  6. #6
    Forum Contributor
    Join Date
    02-15-2016
    Location
    India
    MS-Off Ver
    2016
    Posts
    671

    Re: Serial number with bracket and space genaration for the given input by formula

    Refer attached excel cell E2 in sheet 1.


    If this is difficult / not possible then per input (2 to 20) is it possible to pull the required output by using the Cell E2 texts.
    Attached Files Attached Files

  7. #7
    Forum Contributor
    Join Date
    02-15-2016
    Location
    India
    MS-Off Ver
    2016
    Posts
    671

    Re: Serial number with bracket and space genaration for the given input by formula

    I have found, If the Cell G2 is input (2 to 20) then I2 = <=IFERROR(IF(G2=1,"",LEFT(E2,(FIND(G2,E2,1))+4)),"")> working fine, but is there any way to avoid the cell E2 contents.

  8. #8
    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
    30,879

    Re: Serial number with bracket and space genaration for the given input by formula

    This version uses rows rather than concatenation into one cell

    See sheet2:

    In D1

    =IF($A$1=1,"",IF(ROWS($1:1)<=$A$1,ROWS($1:1)&")_____",""))

    Copy down

    D7 and D9 similar
    Attached Files Attached Files

  9. #9
    Forum Contributor
    Join Date
    02-15-2016
    Location
    India
    MS-Off Ver
    2016
    Posts
    671

    Re: Serial number with bracket and space genaration for the given input by formula

    This works fine for 2 to 20 range in I2 - <=IFERROR(IF(OR(G4<2,G4>20),"",LEFT(E4,(FIND(G4,E4,1))+4)),"")>

  10. #10
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Serial number with bracket and space genaration for the given input by formula

    Much neater to use a small UDF:
    Please Login or Register  to view this content.
    You can then simply use as a formula:
    Formula: copy to clipboard
    Please Login or Register  to view this content.



    If you insist on a formula solution, in one cell, then this horrific creation does it:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    let Source = #table({"Question","Thread", "User"},{{"Answered","Mark Solved", "Add Reputation"}}) in Source

    If I give you Power Query (Get & Transform Data) code, and you don't know what to do with it, then CLICK HERE

    Walking the tightrope between genius and eejit...

  11. #11
    Forum Guru
    Join Date
    02-27-2016
    Location
    Vietnam
    MS-Off Ver
    2024
    Posts
    6,178

    Re: Serial number with bracket and space genaration for the given input by formula

    Delete post...
    Last edited by Phuocam; 04-20-2018 at 07:57 AM.

  12. #12
    Forum Contributor
    Join Date
    02-15-2016
    Location
    India
    MS-Off Ver
    2016
    Posts
    671

    Re: Serial number with bracket and space genaration for the given input by formula

    Hello John
    The Sl. numbers required in single cell instead of multiple cells and concatenate

    Hello Olly
    This is exactly what i want since your formula is omits the helpher cell text of E2. Also i will use your formula solution instead of .xlsm udf.

    Thanks to both of you.

  13. #13
    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
    30,879

    Re: Serial number with bracket and space genaration for the given input by formula

    Olly's formula is concatenation, using "&" to perform the concatenation.

+ 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] Automatically adding a space just before a bracket
    By paradise2sr in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 12-13-2017, 08:28 AM
  2. Replies: 2
    Last Post: 07-18-2014, 03:00 AM
  3. [SOLVED] Copy data from 1 sheet to another sheet base on serial number input
    By Curtis goh in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-17-2013, 11:37 PM
  4. [SOLVED] extract serial number of a date from a textbox input
    By rsbuslon in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 03-20-2013, 02:19 AM
  5. [SOLVED] Create serial numbers based on a single input number.
    By jmp601 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-08-2013, 11:33 AM
  6. Replies: 0
    Last Post: 09-17-2012, 11:56 AM
  7. Finding a serial number in a list of serial numbers
    By zocoloco in forum Excel General
    Replies: 2
    Last Post: 02-04-2009, 05:20 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