Fax con Fivewin

Moderator: Enrico Maria Giordano

Post Reply
User avatar
Pier Luigi
Posts: 58
Joined: Fri Oct 07, 2005 6:30 am
Location: Rome - Italy

Fax con Fivewin

Post by Pier Luigi »

Dovrei realizzare una applicazione per inviare Fax.
Non ho mai affrontato l'argomento.
Avete qualche consiglio da darmi?

Pier Luigi
User avatar
Pier Luigi
Posts: 58
Joined: Fri Oct 07, 2005 6:30 am
Location: Rome - Italy

Re: Fax con Fivewin

Post by Pier Luigi »

Sì, sul computer ho installato WinFax.

Pier Luigi
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Re: Fax con Fivewin

Post by Enrico Maria Giordano »

Code: Select all

FUNCTION SENDFAX( cFax, cDes, cOgg, cMsg )

    LOCAL lOk := .F.

    LOCAL oFax

    BEGIN SEQUENCE
        oFax = CREATEOBJECT( "WinFax.SDKSend" )

        oFax:LeaveRunning()

        IF oFax:SetTo( cDes ) = 1; BREAK; ENDIF
        IF oFax:SetSubject( cOgg ) = 1; BREAK; ENDIF
        IF oFax:SetCoverText( cMsg ) = 1; BREAK; ENDIF
        IF oFax:SetNumber( cFax ) = 1; BREAK; ENDIF

        IF oFax:AddRecipient() = 1; BREAK; ENDIF

        IF oFax:Send( 0 ) = 1; BREAK; ENDIF

        oFax:Done()

        lOk = .T.
    END SEQUENCE

    RETURN lOk
EMG
User avatar
Pier Luigi
Posts: 58
Joined: Fri Oct 07, 2005 6:30 am
Location: Rome - Italy

Re: Fax con Fivewin

Post by Pier Luigi »

Il programma mi segnala

Error: Unresolved external '_HB_FUN_CREATEOBJECT' ...

Io uso Harbour e FW 2.5.

Pier Luigi
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Re: Fax con Fivewin

Post by Enrico Maria Giordano »

Allora sostituiscilo con

Code: Select all

oFax = TOleAuto():New( "WinFax.SDKSend" )
e linka la libreria hbole.lib.

EMG
User avatar
Pier Luigi
Posts: 58
Joined: Fri Oct 07, 2005 6:30 am
Location: Rome - Italy

Re: Fax con Fivewin

Post by Pier Luigi »

Funziona alla grande!

Grazie EMG.

PS
Per curiosità: quale DLL di Winfax viene richiamata?
Post Reply