Hi Barry, I used a "while" loop and Playback() like you suggested. It does the job. Thank you for the suggestion. I just thought there might be some built-in function or parameters in queue.conf that can do the trick.
Thanks. Andy On Thu, Aug 27, 2009 at 12:32 PM, Barry L. Kline<blkl...@attglobal.net> wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Andy Kuo wrote: >> Hi Barry, >> >> Thank you for the hint, but I forgot to mention that we have a few >> advertisements, and we want the callers to listen to only one at a >> time, and in a round robin or random order. Using Playback() doesn't >> seem to serve that purpose. Is there any better way to achieve that? > > > Use the RAND function to generate or pick a filename. > > exten => Set(advert=advert${RAND(1,10)}) > exten => Playback(${advert}) > > That of course assumes that your advertisements are in files named > advert1.xxx through advert10.xxx (where xxx is wav,sln,etc) > > Barry > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.5 (GNU/Linux) > > iD8DBQFKlt9cCFu3bIiwtTARAktAAJ4wFexOIhfN3aCjoIr11MKueZk4swCeK7Xt > RhKepfm4CplaaeCHwtbpzWI= > =6ojM > -----END PGP SIGNATURE----- > > _______________________________________________ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > > AstriCon 2009 - October 13 - 15 Phoenix, Arizona > Register Now: http://www.astricon.net > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users > _______________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- AstriCon 2009 - October 13 - 15 Phoenix, Arizona Register Now: http://www.astricon.net asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users