Contact us


All times are UTC - 8 hours



   [ 3 posts ] 
Author Message
   


Joined: Tue Mar 10, 2015 2:50 pm
Posts: 2
I've downloaded your Dynamic Web Twain Online Demo project and am testing adding a feature. When viewing more than one image at a time we'd like to double-click on an image and programatically set the view mode to display that one image so that the user can zoom in on it (i.e., set view mode to -1 x -1 so we can zoom).

I've added the following function and registered it and verified that it is firing:

function Dynamsoft_OnMouseDoubleClick(index) {
DWObject.SetSelectedImageIndex(index, index);
DWObject.SetViewMode(-1, -1);
}

It works as expected in Chrome, but in IE 10 it always selects the first image.

Steps to reproduce:
1. Load the Sample Images - load all three
2. Set Preview Mode to 2x2
3. Double-click on the third image; in Chrome the page displays the third image, while in IE10 it displays the first image.

How can I make this work in IE?


User avatar
   


Joined: Tue Mar 08, 2005 12:23 am
Posts: 1706
Hi chipdavis,

I have checked your issue in IE 10.

You can try the code below to solve it:

DWObject.RegisterEvent("OnMouseDoubleClick", function (sImageIndex) {
DWObject.SetViewMode(-1, -1);
DWObject.CurrentImageIndexInBuffer = 0;
DWObject.CurrentImageIndexInBuffer = sImageIndex;
});
Please let me know how it works for you.

_________________
Vincy
Dynamsoft Support Team
Follow us@Twitter, Facebook


   


Joined: Tue Mar 10, 2015 2:50 pm
Posts: 2
That works great - thanks!


Display posts from previous:  Sort by  
   [ 3 posts ] 


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
cron
Copyright © 2018 Dynamsoft | All Rights Reserved
dynamic designed by Dynamsoft team
Fatal: Not able to open ./cache/data_global.php