DeeDee
That is indeed possible. However, you need to know which project the map is draw in.
The simples is a latitude-longitude plot (but it is rarely used because the distortion for high latitudes is large). If you know which projection is used, I might be able to help you.
Solutiuon for the lat-lon projection:
**************
Dim MaxX As Integer, MaxY As Integer, MinX As Integer, MinY As Integer 'the pixel coordinates of the map
Dim alon As Single, alat As Single, blat As Single, blon As Single 'the geographic coordinates of the map
'set the 8 parameter to their respective values here...
'The solution is 2 linear equations, calculate the coefficients:
alon = (MinX - MaxX) / (MinLon - MaxLon)
blon = MaxX - alon * MaxLon
'Calculate lon from coordinate
Public Function GetLon(X As Single) As Single
GetLon = (X - blon) / alon
End Function
'Calculate lat from coordinate
Public Function GetLat(Y As Single) As Single
GetLat = (Y - blat) / alat
End Function
************
Sunaj
'The gap between theory and practice is not as wide in theory as it is in practice'