dbRND();
you can use it like:
dbSprite ( SpriteID, dbRND(Max_X), dbRND(Max_Y), ImageID );
where:
SpriteID = id of the sprite
Max_X = maximum x position for spawning
Max_Y = maximum y position for spawning
ImageID = ID of the sprite image
note the dbRND will return a value from 0 to the specified range, so if you want to get like, from 10 - 20, you should:
int randomX = dbRND ( 10 ) +10;
also, dont forget to use dbRandomize(dbTimer()); at the begining of your program, so you get different result everytime you run the program
Hope that helps