Function to generate a random number
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
21-06-17 08:08 PM
Hi
Is there a method to generate a random number in BP of specified length.
Or any other way to do it.
Any advice would be appreciated.
Thanks in advance.
2 REPLIES 2
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
21-06-17 08:49 PM
Getting a random value could be done with codestage: Random = CInt(Math.Floor((upperlimit - lowerlimit + 1) * Rnd())) + lowerlimit
with lower and upperlimit being input variables and Random being your output number variable.
Also your business object needs to import following namespace: Microsoft.VisualBasic
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
22-06-17 02:44 PM
Thanks it worked.
