Search code examples
botframeworkbotsbot-framework-composer

How To generate a random integer in bot composer


I Want to generate a random number and display it to user. Is there a way in composer to do so?


Solution

  • yes , you can use Adaptive expressions prebuilt functions

    ex : ${rand(10,1000)}

    https://learn.microsoft.com/en-us/azure/bot-service/adaptive-expressions/adaptive-expressions-prebuilt-functions?view=azure-bot-service-4.0#rand