Coldfsuion + Java Instantiation Exception

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

  1. #1

    Default Coldfsuion + Java Instantiation Exception

    Hi,

    This is the error I am getting:

    An exception occurred when instantiating a java object. The cause of this
    exception was that: .

    when I try to create the following java object:

    <cfobject action="create" type="java" class="RequestIF" name="reqif">

    <cfset x=reqif.AUTHORIZE>

    <cfset req =
    createObject('java','com.paymentech.orbital.sdk.re quest.Request').init(#x#)>

    Can Somebody please help!!!!!!!



    shailajaj Guest

  2. Similar Questions and Discussions

    1. Java version Exception
      I have cold fusion version: 6,1,0,83762 and I am using j2sdk1.4.1_01 to build my java classes.....when I try to access the java classes..from cold...
    2. java.sql sql exception
      i get a run-time error anytime i run this code, could anyone help. it is an assignment due on monday and i have spent enough hours trying to figure...
    3. java class instantiation problem
      i have a custom java class in ..webinf/classes. the class works fine on my dev box, but fails to instantiate on my prodcution box. both boxes have...
    4. Object Instantiation Exception on move to CVMX 7
      Hi there I am currently migrating from CFMX 6.1 to CFMX 7 and I am having an issue with accessing external java files from within coldfusion even...
    5. PHP dynamic class instantiation like Java
      I've leafed through the docs and user comments on php.net, but haven't been able to find anything related to this. Is there a way to dynamically...
  3. #2

    Default Re: Coldfsuion + Java Instantiation Exception

    Thanks mxstu, I will try that and let you know how it goes.

    mxstu wrote:
    > Try calling the init(#x#) method in a separate statement.
    >
    > Maybe this working example might help? It uses java.io.file to list all files
    > in the current directory.
    >
    >
    >
    > <!--- create file object to lists all files in the current directory --->
    > <cfobject action="create" type="java" class="java.io.File" name="obj">
    > <cfset myCurrDir = getDirectoryFromPath(getTemplatePath())>
    > <cfset dirObj = obj.init(myCurrDir)>
    > <cfset dirList = dirObj.list()>
    >
    > <cfoutput>
    > <b>CurrentDirectory:</b> #myCurrDir#<br>
    > <cfloop from="1" to="#ArrayLen(dirList)#" index="i">
    > #myCurrDir##dirList[i]#<br>
    > </cfloop>
    > </cfoutput>
    helpathand Guest

  4. #3

    Default Re: Coldfsuion + Java Instantiation Exception

    That dint work! I am trying to convert the following code to
    coldfusion.... thats when I get the error :An exception occurred when
    instantiating a java object. The cause of this
    exception was that: .

    Is there a better way to write this code in coldfusion?

    RequestIF request = null;
    request = new Request(RequestIF.AUTHORIZE);

    shailajaj Guest

  5. #4

    Default Re: Coldfsuion + Java Instantiation Exception

    shailajaj,
    Did you ever get PaymenTech working with ColdFusion?

    Dave Hatz
    DaveHatz 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