shakoush2001 0 Newbie Poster

hi there this is my first time I post here, Ive taken some courses in C++ and Iam on my own now, but there are still alot of basic issues I need to work on so please do not mind the following question:

Iam working on a chess interface and I have an TBitmap for every stone, when a stone is to be moved it will be dragged onMouseUP I will check if hte new position is valid, if it is the stone will take its new position else it will return to its former position, the problem is that Iam not able to drag the image what I tried is the following :

1- on mouse down record initialX and initialY
2-While dragging change Top and Left of the TBitmap according to the X an Y coordinates of the event handler

3-OnMouseUp check for the validity of hte position of the TBitmap.

Any help please??

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.