I would like to accept (x,y) coordinate values from the user and decide if the four coordinates form a rectangle.

So I will accept (x1,y1), (x2,y2), (x3,y3) and (x4,y4). The user will just input these in no particular order. What will be the logic to find if these four coordinates can form a rectangle.

I think it is relatively easy, if we can ask the user to enter the left lower, right lower, right upper and left upper coordinates in the order, i.e. (x1,y1)....(x4,y4). Then it is a matter of finding if pairs of sides are equal.

By the way, how do we determine if the lines are going to be at right angles :-)))

Just throw in your ideas (VB code will be appreciated too :-)) )