tag:blogger.com,1999:blog-5824660313967021040.post7612388817326595491..comments2022-03-26T08:56:28.677-07:00Comments on cfSearching: Using iText's PdfPageEventHelper with ColdFusionUnknownnoreply@blogger.comBlogger7125tag:blogger.com,1999:blog-5824660313967021040.post-65739563357919372112008-09-21T23:29:00.000-07:002008-09-21T23:29:00.000-07:00@Murray,I posted Part 1. I will post the second h...@Murray,<BR/><BR/>I posted <A HREF="http://cfsearching.blogspot.com/2008/09/experiment-with-calling-cffunctions.html" REL="nofollow">Part 1</A>. I will post the second half tomorrow.<BR/><BR/>Thanks again for the idea!cfSearchinghttps://www.blogger.com/profile/11564374520734454860noreply@blogger.comtag:blogger.com,1999:blog-5824660313967021040.post-29954352968205948742008-09-19T21:54:00.000-07:002008-09-19T21:54:00.000-07:00@Murray,What do you know? It works. I still do not...@Murray,<BR/><BR/>What do you know? It works. I still do not know if there are other issues, aside from the undocumented part. But it is a pretty cool concept. <BR/><BR/>I will clean up the code an post it tomorrow. (It needs a little explanation).<BR/><BR/>(Now if only I could spell "piqued" ;)cfSearchinghttps://www.blogger.com/profile/11564374520734454860noreply@blogger.comtag:blogger.com,1999:blog-5824660313967021040.post-32377822759623222632008-09-19T14:33:00.000-07:002008-09-19T14:33:00.000-07:00because if that works, it opens the way to creatin...because if that works, it opens the way to creating a generic pageEvent jar for onStartPage, onCloseDocument etc. That would be cool!Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-5824660313967021040.post-10530967734446646402008-09-19T14:07:00.000-07:002008-09-19T14:07:00.000-07:00Cool, I look forward to what you discover. Thanks,...Cool, I look forward to what you discover. <BR/><BR/>Thanks,<BR/>MurrayAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-5824660313967021040.post-36436417529943320192008-09-19T09:10:00.000-07:002008-09-19T09:10:00.000-07:00@Murray,Since you peaked my interest, I will put t...@Murray,<BR/><BR/>Since you peaked my interest, I will put together an example later. Just to see how the idea plays out ;-)cfSearchinghttps://www.blogger.com/profile/11564374520734454860noreply@blogger.comtag:blogger.com,1999:blog-5824660313967021040.post-78957087094442687162008-09-19T09:06:00.000-07:002008-09-19T09:06:00.000-07:00@Murray,Interesting idea. Since CF functions are ...@Murray,<BR/><BR/>Interesting idea. Since CF functions are classes themselves it is probably possible. <BR/><BR/>I have not thought through all of the ramifications. But the first one that comes to mind is that the "function" class is internal to CF (ie undocumented). So its usage incurs the usual risk of the application breaking if anything changes in a future version.cfSearchinghttps://www.blogger.com/profile/11564374520734454860noreply@blogger.comtag:blogger.com,1999:blog-5824660313967021040.post-78629624881574993222008-09-18T13:47:00.000-07:002008-09-18T13:47:00.000-07:00Hi,Thanks again for your blog - I have found lots ...Hi,<BR/><BR/>Thanks again for your blog - I have found lots of useful stuff here.<BR/><BR/>I have been experimenting with the page helper technique outlined in this post and have that working well.<BR/><BR/>I can get a reasonable amount of flexibility by passing the style info in a similar way to your example.<BR/><BR/>However, it occurs to me that an improvement would be if you could get the onPageEnd listener in the java to call a CF function that you plugged in, and then do all the end page stuff in CF rather than java. For example, you could define what your header and footer looks like dynamically and on a pdf by pdf case instead of having to recompile the java whenever you wanted a different type of header / footer that wasnt covered by the style data you pass in.<BR/><BR/>Something like:<BR/>pageEvent = javaLoader.create("itextutil.MyPageEvent").init( myCF_onEndPageFunc);<BR/><BR/>I am only a java dabbler at this stage so I dont know if that could be done. Do you know if you can pass cf functions to java so that you can tell the onEndPage method in the java class to call the cf function?<BR/><BR/>Thanks,<BR/>MurrayAnonymousnoreply@blogger.com