it's my code : ( same code from example medicalviewer leadtools )
Try
RasterCodecs.Startup()
DicomEngine.Startup()
Dim _codecs As RasterCodecs = New RasterCodecs()
Dim _image As RasterImage
_applyToAll = False
_medicalViewer = New MedicalViewer(1, 2)
_medicalViewer.Location = New Point(0, 0)
_medicalViewer.Size = New Size(PanelViewer.ClientRectangle.Right, PanelViewer.ClientRectangle.Bottom)
_medicalViewer.InteractiveInterpolation = True
_medicalViewer.AddAction(MedicalViewerActionType.WindowLevel)
_medicalViewer.AddAction(MedicalViewerActionType.Scale)
_medicalViewer.AddAction(MedicalViewerActionType.Offset)
_medicalViewer.AddAction(MedicalViewerActionType.Stack)
_medicalViewer.AddAction(MedicalViewerActionType.MagnifyGlass)
_medicalViewer.AddAction(MedicalViewerActionType.Alpha)
_medicalViewer.AddAction(MedicalViewerActionType.AnnotationRuler)
_medicalViewer.AddAction(MedicalViewerActionType.AnnotationAngle)
_medicalViewer.AddAction(MedicalViewerActionType.AnnotationText)
_medicalViewer.AddAction(MedicalViewerActionType.AnnotationArrow)
_medicalViewer.AddAction(MedicalViewerActionType.AnnotationRectangle)
_medicalViewer.AddAction(MedicalViewerActionType.AnnotationEllipse)
_medicalViewer.AddAction(MedicalViewerActionType.AnnotationHilite)
_medicalViewer.AddAction(MedicalViewerActionType.RectangleRegion)
_medicalViewer.AddAction(MedicalViewerActionType.EllipseRegion)
_medicalViewer.AddAction(MedicalViewerActionType.FreeHandRegion)
_medicalViewer.AddAction(MedicalViewerActionType.PolygonRegion)
_medicalViewer.AddAction(MedicalViewerActionType.MagicWandRegion)
_medicalViewer.AddAction(MedicalViewerActionType.ColorRangeRegion)
_medicalViewer.AddAction(MedicalViewerActionType.CircleRegion)
_medicalViewer.AddAction(MedicalViewerActionType.SquareRegion)
_medicalViewer.AddAction(MedicalViewerActionType.NudgeTool)
_medicalViewer.AddAction(MedicalViewerActionType.ShrinkTool)
_medicalViewer.SetAction(MedicalViewerActionType.WindowLevel, MedicalViewerMouseButtons.Left, MedicalViewerActionFlags.Active Or MedicalViewerActionFlags.RealTime)
_medicalViewer.SetAction(MedicalViewerActionType.Offset, MedicalViewerMouseButtons.Right, MedicalViewerActionFlags.Active Or MedicalViewerActionFlags.RealTime)
_medicalViewer.SetAction(MedicalViewerActionType.Scale, MedicalViewerMouseButtons.Middle, MedicalViewerActionFlags.Active Or MedicalViewerActionFlags.RealTime)
_medicalViewer.SetAction(MedicalViewerActionType.Stack, MedicalViewerMouseButtons.Wheel, MedicalViewerActionFlags.Active Or MedicalViewerActionFlags.RealTime)
Dim medicalKeys As MedicalViewerKeys = New MedicalViewerKeys()
medicalKeys.MouseDown = Keys.Down
medicalKeys.MouseUp = Keys.Up
medicalKeys.MouseLeft = Keys.Left
medicalKeys.MouseRight = Keys.Right
_medicalViewer.SetActionKeys(MedicalViewerActionType.Offset, medicalKeys)
medicalKeys.Modifiers = MedicalViewerModifiers.Ctrl
_medicalViewer.SetActionKeys(MedicalViewerActionType.WindowLevel, medicalKeys)
medicalKeys.Modifiers = MedicalViewerModifiers.None
medicalKeys.MouseDown = Keys.PageDown
medicalKeys.MouseUp = Keys.PageUp
_medicalViewer.SetActionKeys(MedicalViewerActionType.Stack, medicalKeys)
medicalKeys.MouseDown = Keys.Add
medicalKeys.MouseUp = Keys.Subtract
_medicalViewer.SetActionKeys(MedicalViewerActionType.Scale, medicalKeys)
PanelViewer.Controls.Add(_medicalViewer)
_images = 2
Dim fileName As String = "F:\DICOMDir\IMAGES\1.2.840.113619.2.135.3596.3364290.4716.1221095187.369\1.2.840.113619.2.135.3596.3364290.4647.1221095314.582\1.2.840.113619.2.135.3596.3364290.4647.1221095314.648.dcm"
If (File.Exists(fileName)) Then
_image = _codecs.Load(fileName)
If Not _image Is Nothing Then
cariprop(fileName)
_medicalViewer.Cells.Add(New MedicalViewerCell(_image, False, 1, 1))
_medicalViewer.Cells(i).SetScaleMode(MedicalViewerScaleMode.Fit)
_medicalViewer.Cells(i).SetTag(0, MedicalViewerTagAlignment.TopRight, MedicalViewerTagType.UserData, InstitusiName)
_medicalViewer.Cells(i).SetTag(1, MedicalViewerTagAlignment.TopRight, MedicalViewerTagType.UserData, namaPatient)
_medicalViewer.Cells(i).SetTag(0, MedicalViewerTagAlignment.TopLeft, MedicalViewerTagType.UserData, manufactur)
_medicalViewer.Cells(i).SetTag(4, MedicalViewerTagAlignment.TopLeft, MedicalViewerTagType.Frame)
_medicalViewer.Cells(i).SetTag(6, MedicalViewerTagAlignment.TopLeft, MedicalViewerTagType.Scale)
_medicalViewer.Cells(i).SetTag(2, MedicalViewerTagAlignment.BottomLeft, MedicalViewerTagType.WindowLevelData)
_medicalViewer.Cells(i).SetTag(1, MedicalViewerTagAlignment.BottomLeft, MedicalViewerTagType.FieldOfView)
'_medicalViewer.Cells(0).SetTag(1, MedicalViewerTagAlignment.TopRight, MedicalViewerTagType.UserData, "Good, Guy")
_medicalViewer.Cells(i).SetTag(2, MedicalViewerTagAlignment.TopRight, MedicalViewerTagType.UserData, "PID 125-98-445")
_medicalViewer.Cells(i).SetTag(3, MedicalViewerTagAlignment.TopRight, MedicalViewerTagType.UserData, "DOB 08/02/1929")
_medicalViewer.Cells(i).SetTag(5, MedicalViewerTagAlignment.TopRight, MedicalViewerTagType.UserData, "03/16/1999")
_medicalViewer.Cells(i).SetTag(0, MedicalViewerTagAlignment.BottomLeft, MedicalViewerTagType.RulerUnit)
End If
End If
Catch ex As Exception
' MessageBox.Show(ex.Message, ex.Source)
End Try
this code just call 1 image, ( blue one, is the image location )
and if i scroll down, image hasn't changing ( because image are not XA file ),
may I scrool down, it change to another image ( from another location ),..