Never mind, it was the fact there was no recipient specified. Weird error!...
On 8/24/07, Taco Fleur <[EMAIL PROTECTED]> wrote: > > Hi all, > I've written a CFC to handle sending mail, it worked fine, all of a sudden > it started playing up, the error is pointing to > *834 : </cfmailpart></cfif>* > Which doesn't make sense. I thought it could be the empty BCC, but that > worked before, and I also tried without just to be sure. > See code and error below, any help would be much appreciated. > > A problem occurred when attempting to deliver mail. This exception was > caused by: java.lang.NullPointerException. > > <cffunction > name="send" > access="public" > returntype="void" > output="false"> > > <cflock > name="#getUniqueIdentity()#" > timeout="15" > throwontimeout="yes" > type="exclusive"> > <cfscript> > systemObj = createObject( "java", " java.lang.System" ); > systemObj.setProperty( "mail.host", "clickfind.com.au" ) ; > </cfscript> > </cflock> > > <cfif serverRequiresAuthentication() > > <cfmail > to="#getRecipient()#" > from="#getFrom()#" > cc="#getCarbonCopy()#" > bcc="" > failto="#getFail()#" > replyto="#getReplyTo()#" > subject="#getSubject()#" > server="#getServer()#" > username="#getUserName()#" > password="#getPassword()#" > mailerid="#getMailerID()#" > spoolenable="#yesNoFormat( getSpoolEnable() )#"> > <cfif hasSender() > > <cfmailparam > name="sender" > value="#getSender()#"> > </cfif> > <cfif requestReceipt() > > <cfmailparam > name="Read-Receipt-To" > value="#getFrom()#"> > <cfmailparam > name="Disposition-Notification-To" > value="#getFrom()#"> > </cfif> > <cfmailparam > name="Tracking-Id" > value="#getUniqueIdentity()[EMAIL PROTECTED]()#"> > <!--- > <cfmailparam name="Importance" value=""> > <cfmailparam name="X-Message-Flag" value="Follow up"> > <cfmailparam name="Reply-By" value=""> > <cfmailparam name="X-Priority" value="1"> > ---> > <cfif hasHTMLBody() ><cfmailpart charset="#getCharacterSet()#" > type="html"> > #getHTMLBody()# > </cfmailpart></cfif> > <cfif hasTextBody() or createTextFromHTML() ><cfmailpart > charset="#getCharacterSet()#" type="text"> > <cfif createTextFromHTML() > >#getHTMLBodyAsText()#<cfelse>#getTextBody()#</cfif> > </cfmailpart></cfif> > <cfif hasPlainBody() ><cfmailpart charset="#getCharacterSet()#" > type="plain"> > #getPlainBody()# > </cfmailpart></cfif> > </cfmail> > <cfelse> > <cfmail > to="#getRecipient()#" > from="#getFrom()#" > cc="#getCarbonCopy()#" > bcc="" > failto="#getFail()#" > replyto="#getReplyTo()#" > subject="#getSubject()#" > mailerid="#getMailerID()#" > spoolenable="#yesNoFormat( getSpoolEnable() )#"> > <cfif hasSender() > > <cfmailparam > name="sender" > value="#getSender()#"> > </cfif> > <cfif requestReceipt() > > <cfmailparam > name="Read-Receipt-To" > value="#getFrom()#"> > <cfmailparam > name="Disposition-Notification-To" > value="#getFrom()#"> > </cfif> > <cfmailparam > name="Tracking-Id" > value="#getUniqueIdentity()[EMAIL PROTECTED]()#"> > <cfif hasHTMLBody() ><cfmailpart charset="#getCharacterSet()#" > type="html"> > #getHTMLBody()# > </cfmailpart></cfif> > <cfif hasTextBody() or createTextFromHTML() ><cfmailpart > charset="#getCharacterSet()#" type="text"> > <cfif createTextFromHTML() > >#getHTMLBodyAsText()#<cfelse>#getTextBody()#</cfif> > </cfmailpart></cfif> > <cfif hasPlainBody() ><cfmailpart charset="#getCharacterSet()#" > type="plain"> > #getPlainBody()# > </cfmailpart></cfif> > </cfmail> > </cfif> > > </cffunction> > > > -- > *** http://www.clickfind.com.au > The new Australian search engine for businesses, products and services > *** http://brisbane-web-design.pacificfox.com.au blog > *** Virtual and Dedicated Servers with MS SQL from $250 a month > *** Virtual and Dedicated Servers with registered version of ColdFusion > from $350 a month > *** ColdFusion licenses at the lowest price > -- *** http://www.clickfind.com.au The new Australian search engine for businesses, products and services *** http://brisbane-web-design.pacificfox.com.au blog *** Virtual and Dedicated Servers with MS SQL from $250 a month *** Virtual and Dedicated Servers with registered version of ColdFusion from $350 a month *** ColdFusion licenses at the lowest price --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "cfaussie" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cfaussie?hl=en -~----------~----~----~----~------~----~------~--~---
