Problem instantiating Java Bean

Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.

  1. #1

    Default Problem instantiating Java Bean

    I'm trying to create instantiate a java bean to connect to Novells eDirectory
    server. I downloaded the java beans from novell at
    [url]http://developer.novell.com/ndk/bns_ldap.htm[/url] . Here's the CF Code:
    <cfobject
    action = "create"
    type = "java"
    class = "NWIDirQuery"
    name = "query">

    Initially, I thought simply placing the .jar files in the JVM classpath would
    be sufficient, but I kept getting the "Class not found" error. I then used
    WinZip to explode the file. Now I get the error:

    Object Instantiation Exception.
    An exception occurred when instantiating a java object. The cause of this
    exception was that: NWIDirQuery (wrong name:
    com/novell/beans/NWIDirQuery/NWIDirQuery).

    I'm using a non-J2EE install of ColdFusion MX 6,1,0,83762 on Windows 2003 Std.
    I have very little experience using Java with CF. Any help would be greatly
    appreciated.


    etdavis Guest

  2. Similar Questions and Discussions

    1. webservice returning bean
      Hello All, I have one web service which returns java bean, this bean internally incorporated different beans so my response is like this:...
    2. 500 Java bean field access exception. - Help me
      Hi, Brother?s, i have one problem, if i click in Settings in Serve Settings return the error: 500 Java bean field access exception. Java bean...
    3. Problem instantiating COM object from custom ActiveX DLL
      I've been provided with a custom ActiveX DLL (written in C++) that reads a certiifcate to generate a signature for a passed XML string, and I'm...
    4. trying to return a bean from a java web service...
      hi.. i've been trying to return a bean from a java web service in dotnet, although the add web reference works i keep getting...
    5. instantiating the ASP.DLL
      Is there a way to do a CreateObject("") on the ASP.DLL? TIA Chris
  3. #2

    Default Re: Problem instantiating Java Bean

    You need to specify the full package name when you're instantiating the object.

    eg)

    <cfobject
    action = "create"
    type = "java"
    class = "com.novell.beans.NWIDirQuery.NWIDirQuery"
    name = "query">


    BSterner Guest

  4. #3

    Default Re: Problem instantiating Java Bean

    Thanks, for the help. I am now able to instantiate the object.

    NWIDirQ1 = createObject("Java","com/novell/beans/NWIDirQuery/NWIDirQuery");
    etdavis Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139