|
-
Apr 9th, 2000, 07:38 PM
#1
Thread Starter
Lively Member
I need to get the co-ordinates of some parts of a photo using the mouse and a text box, so that when the user clicks on an certain part of the photo, another form loads up that has information about that individual item. Can anyone help me do this as i've done it before but cannot remember how I did it?
Thanks in advance!
-
Apr 9th, 2000, 08:16 PM
#2
Junior Member
Well what you have to do see good boy is take einsteins theory of relativity and then multiply that by pythagoras's theoram drink ten pints of mongbow have a lay down and then it will once again return to your knowledge banks...if that doesnt work u could always drink ten more pints!!
C ya Ben Gboy
Rhys
-
Apr 9th, 2000, 08:16 PM
#3
Junior Member
ben use the bit of code i give you to find the co ordinates and in a picture1_click type
if X<() and X>() and Y<() and Y>() then
load form2
form2.show
unload form1
in the () put the cordinates
-
Apr 14th, 2000, 11:37 PM
#4
Hello brjames,
I've had the very same problem to solve, except it was for setting the location on an item via a mouse click on the picbox. I looked for the app that I wrote this for but to no avail. I can only tell you what I remember doing to make this happen.
If you look at the help file for the picbox you will see that you can set the pic1.ScaleTop, pic1.ScaleHeight, pic1.ScaleWidth and pic1.ScaleLeft. This is very important to this operation. You will need to get the coordinates for each corner of your map, once you have this then you can assign the coordinates in radiants to the 4 pic1.Scale... properties. You can then use the pic1.X and pic1.Y values convert them to deg. min. sec and then display them in the textbox.
Hope this helps a little,
Roger
-
Apr 16th, 2000, 12:46 AM
#5
Fanatic Member
You can download Microsoft's DirectX 7 DSK or can get it from CHIP computer magazine's few month's back cd if you are from US or India. I don't know wheteher it is available in other countries also.
They have given a very nice tutorial of displaying mouse co-ordinates.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|