cold coffee and hot tea
The last few days that I’ve been working on our DDA Pulse and the PowerPoint Generator updates, I’ve expanded my horizons with the coldfusion and java connection. I’ve used java countless times before, but I think I’m finally starting to get the hang of it. I still don’t think I could actually write a java program in 15 minutes like I could do with coldfusion, but as I learn more about the various java objects, I can start to see future potential projects, or at least how to make some of our existing programming tasks easier. I was having a problem though where errors were being thrown and not caught, or caught and I didn’t provide an ‘out’ for them.
I started out wrapping my cfscript code in a cftry, because I figured that it would catch everything I could ever need to catch, throw the error and then forget about it. I had string captures of the error that were supposed to be printed out to the screen to give me some sort of debugging information. There were return strings in all the appropriate places. Why was I still getting a blank screen and no processed results? The answer to that is, I don’t know. I eventually figured it out without an error message, I was using incorrect variables for my java object calls in two different places, and then another problem on my catch that was closing a filestream I had never opened. Oops. Eventually I brought the cftry into the script and found that it was much more helpful. I couldn’t dump the cfcatch structure, but I instead got a structure that I named myself, in this case, simply ‘e’.
So today’s task will be to figure out how to get the powerpoint slides to clone properly, because right now they’re cloning, but the image is broken. By the end of all this, the administrator will be able to upload a full PowerPoint presentation and the program will automatically break it down into the individual slides, a thumbnail image of the slide, a larger jpg of the slide and add all the relevant information to the database. It’s going to be so cool. I’ve already got the individual slides breaking down into the images, so now off to slide creation!