Página 1 de 1
SetEventHandler
Publicado: Mié Oct 09, 2013 4:32 pm
por a.ilic
Is there alternative for Spirin's method SetEventHandler and event OnSendMail?
I need to manually process the mail when user clicks on mail icon in preview window. I was doing something like this:
oFr:SetProperty("MailExport", "ShowDialog", .F.)
oFr:SetEventHandler("MailExport", "OnSendMail", {|aParams|AppSendMail(aParams)})
where AppSendMail() is my custom function.
Spirin explained that functionality in his group:
https://groups.google.com/d/msg/fastrep ... arbour/OTh 8XLo_kc4/0MqksEYG2ckJ
SetEventHandler
Publicado: Lun Oct 21, 2013 2:06 pm
por a.ilic
Still no answer. Are there any indices that event handlers will be supported in future versions?
SetEventHandler
Publicado: Lun Oct 21, 2013 7:31 pm
por ignacio
Dear Sir,
Sorry for not answering before. I thought it was already answered.
We do not plan support that SetEventHandler method because we believe is a awkward way to work, Please consider to use the export to mail method and use the method SetProperty to set any of the filter parameters.
Example:
WITH OJBECT ::oFastReport1
:SetProperty( "MailExport", "Address", "..." )
:SetProperty( "MailExport", "Subject", "..." )
:SetProperty( "MailExport", "Lines", "..." )
:SetProperty( "MailExport", "FromMail", "..." )
:SetProperty( "MailExport", "FromName", "..." )
:SetProperty( "MailExport", "FromCompany", "..." )
:SetProperty( "MailExport", "Signature", "..." )
:SetProperty( "MailExport", "SmtpHost", "..." )
:SetProperty( "MailExport", "Login", "..." )
:SetProperty( "MailExport", "Password", "..." )
:DoExport( "MailExport" )
END WITH
BTW, if you use the standard FR for [x]Harbour libraries you will need to download again the demo which includes new libraries and a new FRX.DLL.
In case you wan to to use it with Xailer you must wait until next revision since actually there is a bug on the SetProperty method.
Regards,
SetEventHandler
Publicado: Mar Oct 22, 2013 1:20 pm
por a.ilic
ignacio wrote on Mon, 21 October 2013 19:31Please consider to use the export to mail method and use the method SetProperty to set any of the filter parameters.
Example:
WITH OJBECT ::oFastReport1
:SetProperty( "MailExport", "Address", "..." )
:SetProperty( "MailExport", "Subject", "..." )
:SetProperty( "MailExport", "Lines", "..." )
:SetProperty( "MailExport", "FromMail", "..." )
:SetProperty( "MailExport", "FromName", "..." )
:SetProperty( "MailExport", "FromCompany", "..." )
:SetProperty( "MailExport", "Signature", "..." )
:SetProperty( "MailExport", "SmtpHost", "..." )
:SetProperty( "MailExport", "Login", "..." )
:SetProperty( "MailExport", "Password", "..." )
:DoExport( "MailExport" )
END WITH
Dear Ignacio,
Thank you for a quick answer.
I'm aware of this option, but it won't let me to overcome the following situation. When user clicks on send mail icon in preview window, report should be exported to PDF, and then attached and sent via MAPI. This is just one usage example.
So what is needed is the possibility to set OnClick event on some export button(s), and then manually do the export and some other custom operations which may needed to be done.
Regards,
SetEventHandler
Publicado: Mar Oct 22, 2013 9:36 pm
por ignacio
Hello,
Next FR for Xailer revision can show preview on Xailer forms and you can create your own toolbar.
Regards,
SetEventHandler
Publicado: Mié Oct 23, 2013 8:41 pm
por a.ilic
ignacio wrote on Tue, 22 October 2013 21:36Next FR for Xailer revision can show preview on Xailer forms and you can create your own toolbar.
Hi,
What about [x]Harbour users?
Regards,