It's actually pretty simple. Say your rectangle Movieclip has an instance name of, rectangle_mc, and you have different Bitmap textures in your Library, given that each one has their own linkage ID (right-click a bitmap at a time, choose Properties, expand show Advanced, tick/check Export for Actionscript, and in the Identifier field, type something unique, for instance, texture1, then repeat this for the other Bitmaps in your Library, but give each one a unique linkage ID, texture2, texture3, etc.). Finally, in your button click-code (on(relelase) or onRelease or something), type this:

Code:
bitmap = flash.display.BitmapData.loadBitmap("texture1"); // change texture1 for other textures
b = rectangle_mc.getBounds(rectangle_mc);
rectangle_mc.createEmptyMovieClip("mc", 0);
with(rectangle_mc.mc){
	lineStyle(0, 0x000000, 0);
	moveTo(b.xMin, b.yMin);
	beginBitmapFill(bitmap);
	lineTo(b.xMax, b.yMin);
	lineTo(b.xMax, b.yMax);
	lineTo(b.xMin, b.yMax);
	lineTo(b.xMin, b.yMin);
	endFill();
}