Guest User

Untitled

a guest
Apr 23rd, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.80 KB | None | 0 0
  1. <html>
  2. <head>
  3. <title>ActiveX Example 1.1 of SecuGen FDx Pro SDK </title>
  4.  
  5. <script lang=javascript>
  6. <!--
  7. var aaa = 0;
  8. function fnOpenDevice()
  9. {
  10. document.frmmain.objFP.DeviceID = document.frmmain.inc.value;
  11. document.frmmain.objFP.CodeName = document.frmmain.dev.value;
  12. document.frmmain.objFP.MinutiaeMode = document.frmmain.templateFormat.value;
  13.  
  14. // template format of objVerify should be the same to those of objFP[]
  15. objVerify.MinutiaeMode = document.frmmain.templateFormat.value;
  16. return;
  17. }
  18.  
  19. function fnCapture()
  20. {
  21. document.frmmain.objFP.Capture();
  22. var result = document.frmmain.objFP.ErrorCode;
  23. alert(result);
  24. if (result == 0)
  25. {
  26. //var strimg1 = objFP.ImageTextData;
  27. var strmin = document.frmmain.objFP.MinTextData;
  28. alert(strmin);
  29. document.frmmain.min.value = strmin;
  30. }
  31. else
  32. alert('failed - ' + result);
  33.  
  34. return;
  35. }
  36.  
  37. function fnRegister()
  38. {
  39. var strmin1 = document.frmmain.min[0].value;
  40. var strmin2 = document.frmmain.min[1].value;
  41.  
  42. if ( objVerify.RegisterForText(strmin1, strmin2) && objVerify.ErrorCode == 0 )
  43. alert('success- registered');
  44. else
  45. alert('failed - ' + objVerify.ErrorCode);
  46.  
  47. return;
  48. }
  49.  
  50. function fnVerifyEx()
  51. {
  52. var strmin1 = document.frmmain.min[0].value;
  53. var strmin2 = document.frmmain.min[1].value;
  54. var strmin3 = document.frmmain.min[2].value;
  55.  
  56. if ( objVerify.VerifyExForText(strmin1, strmin2, strmin3) && objVerify.ErrorCode == 0)
  57. alert('Success - matched');
  58. else
  59. alert('Failed - ' + objVerify.ErrorCode);
  60.  
  61. return;
  62. }
  63.  
  64. function fnVerify()
  65. {
  66. var strmin1 = document.frmmain.min[0].value;
  67. var strmin2 = document.frmmain.min[2].value;
  68.  
  69. if ( objVerify.VerifyForText(strmin1, strmin2) && objVerify.ErrorCode == 0 )
  70. alert('Success - matched');
  71. else
  72. alert('Failed - ' + objVerify.ErrorCode);
  73.  
  74. return;
  75. }
  76.  
  77. function fnSetimage()
  78. {
  79. document.frmmain.objFP.ImageTextData = document.frmmain.img1.value;
  80.  
  81. return;
  82. }
  83. // -->
  84.  
  85. </script>
  86. </head>
  87.  
  88. <body>
  89. <h4><b>ActiveX Example 1.1 of SecuGen FDx Pro SDK</b></h4>
  90. <p></p>
  91.  
  92. <OBJECT id=objVerify style="LEFT: 0px; TOP: 0px" height=0 width=0
  93. classid="CLSID:8D613732-7D38-4664-A8B7-A24049B96117"
  94. name=objVerify VIEWASTEXT>
  95. </OBJECT>
  96.  
  97. <form name=frmmain>
  98.  
  99. Device Type :
  100. <select name=dev>
  101. <option value=0>FDP02
  102. <option value=1>FDU02
  103. <option value=2>FDU03
  104. <option value=3>FDU04
  105. <option selected value=4>FDU05
  106.  
  107. </select>
  108.  
  109. Instance No. :
  110. <select name=inc>
  111. <option value=-1>-1
  112. <option value=0>0
  113. <option value=1>1
  114. <option value=2>2
  115. <option value=3>3
  116. <option value=4>4
  117. <option value=5>5
  118. <option value=6>6
  119. <option value=7>7
  120. <option value=8>8
  121. <option value=9>9
  122. </select>
  123.  
  124. <p>
  125. Template Format:
  126. <select name=templateFormat>
  127. <option value=256>ANSI 378
  128. <option value=512>SG 400
  129. <option value=768>ISO 19794-2
  130. </select>
  131.  
  132. <input type=button name=open value='Open Device' OnClick='fnOpenDevice();'>
  133. <p>
  134.  
  135. <table border=1 cellspacing=0 cellpadding=0>
  136. <caption> Fingerprint Images </caption>
  137. <tr>
  138. <td>
  139. <OBJECT id=objFP style="LEFT: 0px; WIDTH: 149px; TOP: 0px; HEIGHT: 182px" height=182
  140. width=149 classid="CLSID:D547FDD7-82F6-44e8-AFBA-7553ADCEE7C8" name=objFP VIEWASTEXT>
  141. <PARAM NAME="CodeName" VALUE="1">
  142. </OBJECT>
  143. </td>
  144. </tr>
  145. <tr>
  146. <td align=center><input type=button name=btnCapture1 value='Capture' OnClick='fnCapture();'></td>
  147. </tr>
  148. </table>
  149.  
  150. <p>
  151.  
  152. min1 : <input type=text id=min name=min><br>
  153. <p>
  154. <input type=button name=btnRegister value='Register' OnClick='fnRegister();' style='width:200px'>
  155. <br>
  156. <input type=button name=btnVerify value='VerifyEx' OnClick='fnVerifyEx();' style='width:200px'>
  157. <br>
  158. <input type=button name=btnVerify value='Verify' OnClick='fnVerify();' style='width:200px'>
  159.  
  160. </form>
  161. <script>
  162. fnOpenDevice();
  163. </script>
  164. </BODY>
  165. </HTML>
Add Comment
Please, Sign In to add comment