Here is a tutorial on how to create and implement your own Simulated Ad Server in AI.
1. In AI, place a HorizontalArrangement at top and drop a button onto it. Make both of them Fill parent for Width.
2. Add a Clock and set the TimerInterval to 5000 millisecond (5 second) or as needed. This could also be changed programmatically using Clock.SetInterval
3. Create n (I have created 5 for my test) number of 320 x 48 images (.jpg) that represent your adds. Use a naming convention for your image names; e.g. ad1.jpg, ad2.jpg, ad3.jpg, … FTP the images in some folder on your server; e.g. http://www.MyCompany.com/myAds
5. In Block Editor, create 2 variables (prevImg and nextImg) and set them to same value. Also, create a function getRandomImage — Click HERE to see blocks that are needed.
6. Update the getRandomImage to get random numbers from 1 to max number of images that you have created.
7. In Screen1.Initialize, blank-out your button text, by setting its text to blank (see image in link above)
8. In Clock1.Timer set button.image to invoke getRandomImage
When app starts, every 5 second, it will invoke the getRandomImage function which will retrieve an ad from server and display it as button image.
For another approach for adding adds into AI, please see this LINK.