0

Error:(2, 17) java: package jpcap.net does not exist I added the library file jnetpcap.jar, but the error does not disappear. Compiler intellij idea IDE. Lines

import jpcap.net.JpcapCaptor;

import jpcap.NetworkInterface;

Are red.

  import java.net.NetworkInterface;
    import jpcap.net.JpcapCaptor;
        import jpcap.NetworkInterface;
       public class Main
  {
        jpcap install;
    static NetworkInterface[] array ;
  public static void main (String[] args)
    {
        array = JpcapCaptor.getDeviceList();
        for (int i=1;  i<array.length ; i++)
      {
            System.out.println(i+" -> " + array[i].description);
        }
    }
}
Dmitry
  • 41
  • 1
  • 7

1 Answers1

0

You should add jpcap.dll file to your "system32" folder.

Dirar Houimli
  • 61
  • 1
  • 14