Click or drag to resize

FaxResourceFaxMode Property

The Fax Mode for the last or next operation. This is a choice between Normal and T.38.

Namespace:  VoiceElements.Client
Assembly:  VoiceElementsClient (in VoiceElementsClient.dll) Version: 8.6.1.1
Syntax
public FaxMode FaxMode { get; set; }

Property Value

Type: FaxMode
Remarks
Normal vs T.38

Generally, T.38 is a more reliable protocal and will lead to more successful faxes. However, most SIP carriers do not support T.38 and it may be difficult to find. Before using T.38 mode, you may want to confirm with your carrier that it is available for your use.

Examples
The following two code examples show sending a T38 and a Normal Fax by setting the Fax Mode accordingly.
public static void SendT38Fax()
{
    // To get a channel, you must first get a link to a Telephony Server.  You may need to pass a username password here.
    TelephonyServer m_TelephonyServer = new TelephonyServer();

    // Get your channel resource from the server
    ChannelResource m_ChannelResource = m_TelephonyServer.GetChannel();

    // Get a Fax Resource for the channel
    FaxResource m_FaxResource = m_ChannelResource.GetFaxResource();

    // Set variable for the file to send or receive, you will want your code to deteremine this elsewhere
    string FaxFile = @"C:\FaxFiles\Faxfile1.tif";
    string CleanFaxFile = @"C:\FaxFiles\Faxfile2.tif";

    // Clean up the tif file to be sure with a TifToTif call
    m_TelephonyServer.TifToTif(FaxFile, CleanFaxFile);

    // Set the protocol or mode to T38
    m_FaxResource.FaxMode = FaxMode.T38;

    // Send the Fax
    m_FaxResource.Send(CleanFaxFile);
}

public static void SendNormalFax()
{
    // To get a channel, you must first get a link to a Telephony Server.  You may need to pass a username password here.
    TelephonyServer m_TelephonyServer = new TelephonyServer();

    // Get your channel resource from the server
    ChannelResource m_ChannelResource = m_TelephonyServer.GetChannel();

    // Get a Fax Resource for the channel
    FaxResource m_FaxResource = m_ChannelResource.GetFaxResource();

    // Set variable for the file to send or receive, you will want your code to deteremine this elsewhere
    string FaxFile = @"C:\FaxFiles\Faxfile1.tif";
    string CleanFaxFile = @"C:\FaxFiles\Faxfile2.tif";

    // Clean up the tif file to be sure with a TifToTif call
    m_TelephonyServer.TifToTif(FaxFile, CleanFaxFile);

    // Set the protocol or mode to "Normal"
    m_FaxResource.FaxMode = FaxMode.Normal;

    // Send the Fax
    m_FaxResource.Send(CleanFaxFile);
}
See Also