remove the image_click replace with
Private Sub Image1_MouseUp(ByVal Button As Integer, _
ByVal Shift As Integer, ByVal x As Single, ByVal y As Single)
Dim f#
With Me.Frame1
If .ScrollBars = fmScrollBarsNone Then
.ScrollBars = fmScrollBarsBoth
Me.Image1.AutoSize = True
.ScrollHeight = Image1.Height
.ScrollWidth = Image1.Width
f = (Image1.Height / .Height)
.ScrollTop = (y - .Top) * f
.ScrollLeft = (x - .Left) * f
Else
.ScrollTop = 0
.ScrollLeft = 0
.ScrollWidth = .Width
.ScrollHeight = .Height
.ScrollBars = fmScrollBarsNone
Me.Image1.AutoSize = False
Me.Image1.Height = .InsideHeight
Me.Image1.Width = .InsideWidth
End If
End With
End Sub
--
keepITcool
|
www.XLsupport.com | keepITcool chello nl | amsterdam
Jens Meier wrote :
keepITcool schrieb:
as I said..
you load the hires picture (which initially is shown as a
thumbnail.)
IF you want to actually swap hires and lores pictures
(reread from disk) you must include some code to do that.
OK,
that's clear to me - the high-res picture is shown as a thumbnail.
But on the event of clicking the image, how can I possibly pan it to
be centered on the mouseclick position?? And zoomed in?
I played around with ScrollWidth/Height/..., but got no results...
Thanks again,
Jens