Foro de elhacker.net

Programación => Java => Mensaje iniciado por: mapers en 28 Abril 2015, 18:35 pm



Título: Libreria Jacob
Publicado por: mapers en 28 Abril 2015, 18:35 pm
Buenas gente del foro necesito de sus sabios conocimientos, lo que sucede esque trato de utilizar la libreria jacob para poder levantar el ejemplo java que viene en ByteScout para grabar el escritorio del cliente el ejemplo es el siguiente :

Código
  1.  
  2. /*
  3. If you are running your Java application on Windows then you may use Screen Capturing SDK from Java using the Jacob library ( you may get it from http://danadler.com/jacob/ )
  4.  
  5. The final code (using Jacob) code should look like this
  6. */
  7. import com.ms.com.*;
  8. import com.ms.activeX.*;
  9.  
  10. public class DispatchTest
  11. {
  12. public static void main(String[] args)
  13. {
  14.   ActiveXComponent captureLib = new ActiveXComponent("BytescoutScreenCapturing.Capturer");
  15.   Object capturer = captureLib.getObject();
  16.   try {
  17.     // output file name
  18.     Dispatch.put(capturer, "OutputFileName", "EntireScreenCaptured.wmv");
  19.    // output width
  20.    Dispatch.put(capturer, "OutputWidth", 640);
  21.    // output height
  22.     Dispatch.put(capturer, "OutputHeight", 480);
  23.    // setting the capturing type to 3 (entire screen)
  24.     Dispatch.put(capturer, "CapturingType", 3);
  25.  
  26.    // run the recording
  27.     Variant f = new Variant(false);
  28.     Dispatch.call(workbook, "Run", f);
  29.  
  30.     // record for 5 seconds
  31.     Thread.sleep(4000);
  32.  
  33.   } catch (Exception e) {
  34.     e.printStackTrace();
  35.   } finally {
  36.           ;
  37.   }
  38. }
  39. }
  40.  
  41.  

Trato de compilar pero no se puede.

El problema esta que no reconoce al objeto workbook o es que la libreria esta desfasada, gracias por su tiempo .