Home |
Search |
Today's Posts |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
What are the grid coordinates at top left and bottom right corners. Does the
meridian intersect, Europe so I guess it does, at what distance from the left, as a fraction of the total width (ie a decimal between 0 & 1). What is width & height of the image (get from properties). Double check that coord's along the centre and vertical lines are as you would expect (ie the scales linear). Regards, Peter T "Paul" wrote in message ... Peter, Thanks for the reply that helps a lot just a couple of things I can't figure out and that has mostly to do with the co-ordinates; I've got a map, from google earth, and I'm using co-ordinates in degrees, minutes (so 51 08N21 47E, etc etc), and I can't get the right co-ordinates to be displayed on my map. If I reach the top of my map one of the values states zero, but it should state 51 degrees 08 minutes North instead of zero. Could you help me? Cheers, Paul "Peter T" wrote: Indeed you can embed a an image into the entire form or probably better into an Image control. Click the "Picture" property and browse to your image. Set AutoSize to true and experiment with PictureSizeMode. Maybe later you can change Autosize to false. In the form code (assuming the image control is named Image1) Private Sub Image1_MouseDown(ByVal Button As Integer, _ ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single) Range("A1").Value = X Range("B1").Value = Y End Sub Private Sub Image1_MouseMove(ByVal Button As Integer, _ ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single) Me.Caption = X & " " & Y End Sub You will of course need to calibrate X & Y to relate to your map coordinates. Assuming the Grid is linear in both axes (don't assume it is), maybe something like this With Image1 east = (.Width / X) x (maxEast - minEast) north = (.Height/ Y) x (maxNorth - minNorth) End With where max/min East/north are grid coord's at left, right top & bottom of the map Regards, Peter T "Paul" wrote in message ... Hi, Is it possible to embed a map into a userform? What I'm trying to accomplish is that a map, lets say europe, is displayed and everytime when the user clicks on the map the lat/long coordinates of the pointer are transferred to an excel sheet. Any ideas? Cheers, Paul |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
error with userform, "unable to create embedded object" | Excel Programming | |||
Userform Image Control and embedded images | Excel Programming | |||
Displaying embedded chart on userform | Excel Programming | |||
Chart embedded in UserForm | Excel Programming | |||
unable to create embedded object on a userform | Excel Programming |