VintaSoft Annotation .NET Plug-in Discussions

Questions, comments and suggestions concerning VintaSoft Annotation .NET Plug-in.

Board index < VintaSoft Imaging < VintaSoft Annotation .NET Plug-in Discussions

We are migrating to new forums engine, no new registration or posting currently available. TIA for your patience.

Set the AnnotationViewer's Current Image



Set the AnnotationViewer's Current Image

Post by Junhui »

Hello, Alex. I have a problem with AnnotationViewer.
I got the image files from DB, and maked them to VintasoftImages, and added to annotationViewer's ImageCollection.
My Codes are below,
foreach(...)
{
...
VintasoftImage img = new VintasoftImage(mstream);
annotationViewer1.Images.Add(img);
...
}

After that, I inserted image file to annotationViewer's ImageCollection.
My Codes are below,
{
VintasoftImage img = new VintasoftImage(_sourceStream);
annotationViewer1.Images.Insert(0, img); //not add(), want to insert at the top.
}

When I run my code, _sourceStream image inserted ordinarily at the top of my AnnotatedThumbnailViewer.
But annotationViewer1's image doesn't change to the inserted image.
I want to change image not only AnnotatedThumbnailViewer but also AnnotationViewer when I inserted image.
I tried these codes below but they didn't work.
{
VintasoftImage img = new VintasoftImage(_sourceStream);
annotationViewer1.Images.Insert(0, img);
annotationViewer1.FocusedIndex = 0;
}
or...
{
VintasoftImage img = new VintasoftImage(_sourceStream);
annotationViewer1.Images.Insert(0, img);
annotationViewer1.Refresh();
}
or...
VintasoftImage img = new VintasoftImage(_sourceStream);
annotationViewer1.Images.Insert(0, img);
annotationViewer1.Images[0].SetImage(new VintasoftImage(_sourceStream));
}
they all didn't work properly.
I want your some advice to handle this problem.

Best Regards,
Jun-Hee.


Re: Set the AnnotationViewer's Current Image

Post by Junhui »

I know when I use Add(), can change current image of annotationViewer1's image properly.
Like codes below,
{
...
annotationViewer1.Images.Add(_sourceStream);
annotationViewer1.FocusedIndex = annotationViewer1.Images.Count - 1;
...
}

But I want to "Insert" image at the top of the annotatedThumbnailViewer,
so I inserted image at ImageCollection's 0 index.
{
annotationViewer1.Images.Insert(0, img);
annotationViewer1.FocusedIndex = 0;
}
They didn't work properly.(annotationViewer's image doesn't change) So I need your some advice.

Best Regard,
Jun-Hee.


Re: Set the AnnotationViewer's Current Image

Post by Alex »

Hello Jun-Hee,

Thank you for your message and good description of the problem, we have fixed the problem in version 5.0.5.1 of VintaSoftImaging.NET SDK.

Best regards, Alexander


Page 1 from 1: 1