Board index » cppbuilder » EasyMail Objects and C++Builder 4

EasyMail Objects and C++Builder 4

I am considering to buy QuickSoft EasyMail Objects 5 to handle all my
email messaging. They come in a *.dll COM Automation Server format.

To use them in my application I tried to use:

Variant emPop3;
emPop3 = Variant::CreateObject("EasyMail.POP3.5");

This works fine and I can access its properties using
emPop3.Exec(PropertySet("MailPort") <<110);
...
and its methods using
emPop3.Exec(Function("Connect"));

My problem is: how do I access the events fired back to my application?
If there is no way how to access them, is there another way to
communicate with this COM objects?

Thank you for help.
Alex.

 

Re:EasyMail Objects and C++Builder 4


Alexander, you probably should import the type library first and then
use the facilities provided by BCB4. I posted a sample recently.

As for the emailing, I'm very happy with the VCL controls that are part
of the BCB4.

Alex

Quote
Alexander Kovacic wrote:

[snip]

Re:EasyMail Objects and C++Builder 4


Alex,

thank you for a reply.
I am not happy with the NetMasters' nmPOP3 component, it has few
limitations and there is no way how to reset the component if the
connection to the mail server is accidentally interrupted and the
application hangs. That was the reason I started to look elsewhere ...

As to the Project/Import Type Library, that is where I started, but the
created EMPOP3Lib_TLB.h contained:

#error "This file requires a newer version of the header UTILCLS.H" \
       "You need to apply an update/patch to your copy of C++Builder"

(I have both service packs installed). During the execution I was getting
exceptions for no reason at all. So I tried to use the Variant option ...
but now there is the problem with the events.

Alex.

Re:EasyMail Objects and C++Builder 4


Quote
Alexander Kovacic wrote in message <38B35FE2.5BB38...@bigpond.com>...
>My problem is: how do I access the events fired back to my application?
>If there is no way how to access them, is there another way to
>communicate with this COM objects?

Salutation,

I am also using Quiksoft EzMail 5 component in BCB 4.0. There is two ways
you can handle the events of the component

1- Handle the COM event (i still haven't found any info on handling COM
event so far)

2- Use the Callback feature of the component

Example : In the SMTP Object

pEzMail->SetProgressCallback( YourCallBack, 0 );

Although the callback feature seems to works, i still do i have problems
with it.

In my case, the program call the callback correctly the first time but then
do an access violation as soon as it exit the callback. I don't know if it
is my fault or the component fault but you might try it for yourself and see
what happens.

Francois Belair

Re:EasyMail Objects and C++Builder 4


Seems like the patch wasn't applied properly ( failed ).

alex

Quote
Alexander Kovacic wrote:

> Alex,

> thank you for a reply.
> I am not happy with the NetMasters' nmPOP3 component, it has few
> limitations and there is no way how to reset the component if the
> connection to the mail server is accidentally interrupted and the
> application hangs. That was the reason I started to look elsewhere ...

> As to the Project/Import Type Library, that is where I started, but the
> created EMPOP3Lib_TLB.h contained:

> #error "This file requires a newer version of the header UTILCLS.H" \
>        "You need to apply an update/patch to your copy of C++Builder"

> (I have both service packs installed). During the execution I was getting
> exceptions for no reason at all. So I tried to use the Variant option ...
> but now there is the problem with the events.

> Alex.

--
HotSend - portable documents technology
http://www.hotsend.com/
eFax - get your faxes via email - Free !
http://www.efax.com

Re:EasyMail Objects and C++Builder 4


Hi Francois,

it is a pleasure to know I am not alone with my problem ...
I will try to use the callback functions, during the weekend and will let you
know my progress. So far, I am not able to access the type library interface
because of the problem with the utilcls.h, but will keep trying using the
Variant options.

Alex.

Quote
Francois Belair wrote:
> Alexander Kovacic wrote in message <38B35FE2.5BB38...@bigpond.com>...
> >My problem is: how do I access the events fired back to my application?
> >If there is no way how to access them, is there another way to
> >communicate with this COM objects?

> Salutation,

> I am also using Quiksoft EzMail 5 component in BCB 4.0. There is two ways
> you can handle the events of the component

> 1- Handle the COM event (i still haven't found any info on handling COM
> event so far)

> 2- Use the Callback feature of the component

> Example : In the SMTP Object

> pEzMail->SetProgressCallback( YourCallBack, 0 );

> Although the callback feature seems to works, i still do i have problems
> with it.

> In my case, the program call the callback correctly the first time but then
> do an access violation as soon as it exit the callback. I don't know if it
> is my fault or the component fault but you might try it for yourself and see
> what happens.

> Francois Belair

Other Threads