Page 1 of 1

WinFax OLE

Posted: Sat Apr 22, 2006 2:24 pm
by Enrico Maria Giordano
Dear friends, I'm searching for samples on how to drive WinFax via OLE.

Thank you.

EMG

Re: WinFax OLE

Posted: Sat Apr 22, 2006 5:04 pm
by Enrico Maria Giordano
I answer myself. This is a working sample:

Code: Select all

#include "Fivewin.ch"


FUNCTION MAIN()

    LOCAL oDlg

    DEFINE DIAlOG oDlg

    @ 1, 1 BUTTON "Send fax";
           ACTION SENDFAX()

    ACTIVATE DIALOG oDlg;
             CENTER

    RETURN NIL


STATIC FUNCTION SENDFAX()

    LOCAL oFax := CREATEOBJECT( "WinFax.SDKSend" )

    oFax:LeaveRunning()

    oFax:SetCoverText( "This is the fax cover." )

    IF FILE( CURDRIVE() + "\" + CURDIR() + "\TEST.DOC" )
        oFax:AddAttachmentFile( CURDRIVE() + "\" + CURDIR() + "\TEST.DOC" )
    ENDIF

    oFax:SetNumber( "your fax number" )
    oFax:AddRecipient()
    oFax:Send( 0 )

    RETURN NIL
EMG

Posted: Sat Apr 22, 2006 7:16 pm
by Antonio Linares
Enrico,

Very good, master :)

Posted: Sat Apr 22, 2006 8:11 pm
by Enrico Maria Giordano
:wink:

Posted: Sun Apr 23, 2006 1:56 am
by RAMESHBABU
Hi Mr.Enrico
LOCAL oFax := CREATEOBJECT( "WinFax.SDKSend" )
How do I get this object. Should I link any library like WINFAX.LIB
supplied with BCC55\LIB\PSDK or any DLL ?

Regards

- Ramesh Babu P

Posted: Sun Apr 23, 2006 2:24 am
by Taiwan
Hello RAMESHBABU,

I think no. Because You should be install WinFax software.
It's include ActiveX DLL or OCX ....file and start itself.

Regards,

Richard

Posted: Sun Apr 23, 2006 9:53 am
by Enrico Maria Giordano
Taiwan wrote:Hello RAMESHBABU,

I think no. Because You should be install WinFax software.
It's include ActiveX DLL or OCX ....file and start itself.

Regards,

Richard
Exactly.

EMG