web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Answered

Increment alphanumeric characters

(0) ShareShare
ReportReport
Posted on by 8
Hello, 
I have a custom requirement where I need to increment a combination of characters (0-9, then following 9 it should go from A-Z) for a custom field
Example : 01, 02...09, 0A, 0B..., 0Z, 10,11...19, 1A...etc.
Can anyone give me an insight how this could be implemented please?
I have the same question (0)
  • Suggested answer
    Kevin Xia Profile Picture
    Microsoft Employee on at
    Increment alphanumeric characters
    Hi,
    From your logic point of view, the code that implements this logic is not complicated:
    Take the second character, 0-9, a-z as a cycle, that is, 36 characters as a cycle; Suppose there are a hundred such fields, then the hundredth should be, 100 divided by 36 equals 2 remainder 28, which means that the hundredth is in the 28th position of the third loop, then the first character corresponds to 2, and the second character corresponds to R, that is, the value of the hundredth digit is 2R.
    I don't know if I explained it like that, do you understand?
    Best regards,
    Kevin
  • Jason0810M Profile Picture
    8 on at
    Increment alphanumeric characters
    Hello Kevin,
     
    I did not understand the part about the hundredth.
    Actually the numbers should go from 00 to ZZ, with the range of characters going from 0 to 9 then A to Z.
  • Suggested answer
    Kevin Xia Profile Picture
    Microsoft Employee on at
    Increment alphanumeric characters
    Hi,
    First of all, your requirements involve custom development, and secondly, the part about the hundredth is an example i given to help you refine the logic in this area. Think the range of characters going from 0 to 9 then A to Z as a cycle. As another example, 00 means the first number of the first cycle, 01 means the second number of the first cycle, and 11 means the second number of the second cycle. These two examples will help you write custom code for the relevant logic.
    Best regards,
    Kevin
  • Verified answer
    André Arnaud de Calavon Profile Picture
    299,078 Super User 2025 Season 2 on at
    Increment alphanumeric characters
    Hi Jason,
     
    The NumberSeq class has a feature to increment letters. You can have a look at this class to get an example.
  • Jason0810M Profile Picture
    8 on at
    Increment alphanumeric characters
    Thanks Andre,
    I have managed to implement my custom logic using the two methods numRemoveFormatV2 and numInsertFormatV2 from the NumberSeq class. I have passed the format based if the character is a number or not (using str2NumOK method to differentiate between the two cases) and it works perfectly fine.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
CA Neeraj Kumar Profile Picture

CA Neeraj Kumar 2,188

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 868 Super User 2025 Season 2

#3
Sohaib Cheema Profile Picture

Sohaib Cheema 593 User Group Leader

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans