How to restrict user to enter unique names in numbered list?

My requirement is to create numbered list and to restrict user to enter duplicate values for display name property. Please assist how can I achieve this functionality?

Tagged:

Answers

  • Hi @bhubeshrana ,

     

    You can create one module with only a number list as your dimension & add two line items for display name & to check duplicate here.

     

    Screenshot_250.png

    Screenshot_251.png

     

    hope this will helps

    Thanks

    Akhtar

     

  • @bhubeshrana 

    Possibly you cannot restrict or prevent the user to enter duplicate names in the numbered list as this is one of its characteristic.

    You can highlight the duplicate names as @Akhtar.shahbaz has shown. This might act as a warning sign for the end user.

     

    ~Anand

     

     

    https://in.linkedin.com/in/anand-shekhawat-35645486

  • One way to do it so to use the name as the code at point of insertion this should prevent the same name from being applied in the numbered list

  • You can use Code in numbered lists to enter names, The numbered list property itself will restrict on entering duplicate values. You can also set Display name property to show Code.

     

    mohitlamba0101_1-1635119780103.png 

    Now, according to image shown above if I try to repeat "User 5", Anaplan throws an error!

     

    mohitlamba0101_2-1635119956867.png

     

    Although if you want to warn user when they enter duplicate name:

    1. Use ISFIRSTOCCURANCE to check if the entry holds unique display name or not.

    2. Make another line item to put comments like "Try different Name" by using If Then Else functionality when the name is repeated.

     

    mohitlamba0101_0-1635118466377.png

    Hope it helps!

  • @bhubeshrana 

     

    Quick question:

    • why does the list need to be a numbered list if you are having to restrict user input to not duplicate the members?  As @anand.shekhawat stated, having duplicate members as the display name is one of the main characteristics of a numbered list.

    Now, if it has to be a numbered list and the requirement is to not allow users to enter duplicate values, I would potentially go down this route.

    • Create a "flat" list with valid values, like Promotions Flat
    • The Display Name should be formatted as Text.  In the SYS module storing the logic, create a line item with the formula Finditem(Promotions Flat, Display Name).  Name it Add Promotion
    • Create a Boolean line item called Load? with the formula Isblank(Add Promotion)
    • create a view, using Load? as the filter.
    • Create an action to load the new member to the list
    • Create another view using Load? as the filter and call the view Load to Promotions Flat.  You need this view because you cannot use the same view in multiple actions within a process.
    • Create a Process adding the above two actions (loading to the list, loading to Promotions Flat)

     

    Hope this helps,

     

    Rob