Example capx
The idea is that the red Sprite2 is smaller than the black Sprite.
Each tick that red is overlapping black, test that the left and right boundaries of Red are in between the Black left and right boundaries and do the same for the top and bottom boundaries.
The code in the capx works because the origin point is in the middle of the texture and so Sprite.X - (Sprite.width / 2) gives the left boundary position, Sprite.X + (Sprite.width / 2) gives the right, etc...
Note: the parenthesis in the formula are not mathematically necessary but help visualising the priority of the operations.