1 Reply Latest reply on Jul 1, 2014 9:31 AM by Nicholas_Bostaph

    cfwindow debugging


      We have switched to using CFWindows for our modal dialogs in our application.  While we have debugging turned on for our IP addresses, and the debugging information shows up just fine on normal pages, nothing appears in cfWindows. Today I went about trying to recreate the debugging information and manually write it out to the window HTML. I began by using the following code in onRequestEnd, which worked fine on pages called normally:


      <cfset tempFactory = createObject("java", "coldfusion.server.ServiceFactory")>
      <cfset tempCfdebugger = tempFactory.getDebuggingService()>
      <cfset qEvents = tempCfdebugger.getDebugger().getData()>


      After taking the time to format the output as desired, I finally tried this on a cfWindow. However, I received the following error on the third line of code:


      Detail  Its possible that a method called on a Java object created by CreateObject returned null.
      ErrNumber 0
      Message   Value must be initialized before use.


      This implies that it's not just that CF is set not to display debugging information in cfWindows, but that the Java elements that supply the debugging information don't work the same in the case of cfWindows. I understand very little about the underlying Java, and the code I posted was taken from a CF blog some time ago, so I'm not sure how to troubleshoot this issue.


      I have tried opening the CFWindow templates in their own browser window. Debugging information appears as normal. I then tried CFDumping the results of each of the three lines listed above. The first two work. The "tempCfdebugger" variable does contain a function called "getDebugger()". The problem seems to be when that function is called within a CFWindow. The server must be somehow interpreting CFWindow requests differently.


      Is there a different way to get this debugging information other than connecting to the ServiceFactory?