Melvin,
     
     In your case your appli cannot find the dll OCFPCSC1.DLL. 
     You get 2 solutions: 
     Copy all the dll from the C:\OpenCard\OCF1.2\lib to your project or 
     add C:\OpenCard\OCF1.2\lib in your path of your environment variable.
     
     Hope it's help
     
     Jerome
     
     


______________________________ Reply Separator _________________________________
Subject: RE: [OCF]  Error in running sample application
Author:  mpvivas ([EMAIL PROTECTED]) at internet
Date:    8/15/01 5:05 AM


I have already copied the opencard.properties file to jre/lib and executed 
the class file again. I encountered the following error when running the 
class.
     
Exception in thread "main" java.lang.UnsatisfiedLinkError: no OCFPCSC1 in 
java.library.path
     
        at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1312) 
        at java.lang.Runtime.loadLibrary0(Runtime.java:749)
        at java.lang.System.loadLibrary(System.java:820) 
        at
opencard.core.util.SystemAccess.loadLibrary(SystemAccess.java:111)
        at
com.ibm.opencard.terminal.pcsc10.OCFPCSC1.loadLib(OCFPCSC1.java:64)
        at
com.ibm.opencard.terminal.pcsc10.Pcsc10CardTerminalFactory.open(Pcsc10CardTe 
rmin
alFactory.java:94)
        at
com.ibm.opencard.terminal.pcsc10.Pcsc10CardTerminalFactory.<init>(Pcsc10Card 
Term
inalFactory.java:65)
        at java.lang.Class.newInstance0(Native Method) 
        at java.lang.Class.newInstance(Class.java:237) 
        at
opencard.core.service.SmartCard.handleTerminalFactoryEntries(SmartCard.java: 
424)
     
        at
opencard.core.service.SmartCard.configureTerminalRegistry(SmartCard.java:261 
)
        at opencard.core.service.SmartCard.start(SmartCard.java:534) 
        at ReadFile.main(ReadFile.java:14)
     
Thanks for the help.
     
regards,
melvin
     
     
-----Original Message-----
From: Harley V. Barrales [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, August 15, 2001 5:29 PM
To: Melvin Dave P. Vivas; [EMAIL PROTECTED] 
Subject: Re: [OCF] Error in running sample application
     
     
Melvin,
     
        This problem can be solved by creating (or copying) an opencard.properti
es
file to the JRE/Lib folder or to the current folder where you store your 
classes.
     
        See OCF Programming guide for details.
     
     
Cheers,
     
Harley
8/15/01 5:21:48 PM, "Melvin Dave P. Vivas" <[EMAIL PROTECTED]> wrote:
     
>
>I'm new to developing apps for smart cards.
>I'm testing the sample application in the OCF docs but I get the following 
>error when executing the class file.
>
>opencard.core.util.OpenCardPropertyLoadingException: property file not 
found
>        at
>opencard.opt.util.OpenCardPropertyFileLoader.loadProperties(OpenCardPropert 
y
>File
>Loader.java:158)
>        at opencard.core.service.SmartCard.start(SmartCard.java:520) 
>        at ReadFile.main(ReadFile.java:14)
>
>ReadFile.java
>
>import opencard.core.service.SmartCard; 
>import opencard.core.service.CardRequest;
>import opencard.opt.iso.fs.FileAccessCardService; 
>import opencard.opt.iso.fs.CardFile;
>import opencard.opt.util.OpenCardPropertyFileLoader; 
>
>public class ReadFile {
>
>  public static void main(String[] args) 
>  {
>    System.out.println("reading smartcard file..."); 
>
>    try {
>      SmartCard.start();
>
>
>   // wait for a smartcard with file access support 
>      CardRequest cr =
>        new CardRequest(CardRequest.ANYCARD, null, 
>FileAccessCardService.class);
>      SmartCard   sc = SmartCard.waitForCard(cr); 
>
>      FileAccessCardService facs = (FileAccessCardService)
>        sc.getCardService(FileAccessCardService.class, true); 
>      CardFile root = new CardFile(facs);
>      CardFile file = new CardFile(root, ":c009"); 
>
>      byte[] data = facs.read(file.getPath(), 0, 
>                             file.getLength() ); 
>      sc.close();
>      System.out.println("sc closed"); 
>
>      String entry = new String(data); 
>      entry = entry.trim();
>      System.out.println(entry);
>
>    } catch(Exception e) {
>      e.printStackTrace(System.err); 
>
>    } finally { // even in case of an error... 
>
>      try {
>        SmartCard.shutdown();
>      } catch(Exception e) {
>        e.printStackTrace(System.err); 
>      }
>    }
>
>    System.exit(0);
>  }
>}
>
>What seems to be the problem?
>
>Melvin Dave P. Vivas
>Programmer
>Infinit-E Asia, Inc.
>25th Flr. IBM Bldg., Eastwood City Cyberpark, 
>Quezon City, Philippines
>Tel. No. 995-7777 loc. 140; 995-8075 
>
>
>
>---
>> Visit the OpenCard web site at http://www.opencard.org/ for more 
>> information on OpenCard---binaries, source code, documents.
>> This list is being archived at http://www.opencard.org/archive/opencard/ 
>
>! To unsubscribe from the [EMAIL PROTECTED] mailing list send an email 
>! to
>!                           [EMAIL PROTECTED] 
>! containing the word
>!                           unsubscribe 
>! in the body.
>
     
     
     
     
_________________________________________________________ 
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com
     
     
     
---
> Visit the OpenCard web site at http://www.opencard.org/ for more 
> information on OpenCard---binaries, source code, documents.
> This list is being archived at http://www.opencard.org/archive/opencard/
     
! To unsubscribe from the [EMAIL PROTECTED] mailing list send an email 
! to
!                           [EMAIL PROTECTED] 
! containing the word
!                           unsubscribe 
! in the body.
     



---
> Visit the OpenCard web site at http://www.opencard.org/ for more
> information on OpenCard---binaries, source code, documents.
> This list is being archived at http://www.opencard.org/archive/opencard/

! To unsubscribe from the [EMAIL PROTECTED] mailing list send an email
! to
!                           [EMAIL PROTECTED]
! containing the word
!                           unsubscribe 
! in the body.

Reply via email to