【问题标题】:RightFax 10.0 Integration With C#RightFax 10.0 与 C# 的集成
【发布时间】:2012-06-17 20:56:17
【问题描述】:

如果我将值插入到 RightFax 的相应表中,它是自动传真还是需要为此编写以下代码?

RFCOMAPILib.FaxServerClass faxserver = new RFCOMAPILib.FaxServerClass(); 
faxserver.ServerName = "ServerName"; 
faxserver.Protocol = RFCOMAPILib.CommunicationProtocolType.cpNamedPipes; 
faxserver.UseNTAuthentication = RFCOMAPILib.BoolType.True; 
faxserver.OpenServer(); 

RFCOMAPILib.Fax fax = (RFCOMAPILib.Fax) faxserver.get_CreateObject(RFCOMAPILib.CreateObjectType.coFax); 

// set up your 'fax' object the way you want it, below is just some sample options 
fax.ToName = "John Doe"; 
fax.ToFaxNumber = "4255551111"; 
fax.ToVoiceNumber = "4255550000"; 
fax.ToCompany = "ACME"; 
fax.FromName = "My Company"; 
fax.FromVoiceNumber = "4255552222"; 

fax.Send(); 

能否提供附件示例代码?如果 RightFax 自动发送传真,那么我需要填写哪些表格才能做到这一点?

谢谢

【问题讨论】:

    标签: rightfax


    【解决方案1】:

    下面的代码是 vb.net,但会告诉你如何发送传真和添加附件,希望这有帮助。我已经写了一篇关于这个here 的帖子,但下面是代码......

    Dim FaxAPI As RFCOMAPILib.FaxServer
    Dim fFax As RFCOMAPILib.Fax
    FaxAPI = New RFCOMAPILib.FaxServer
    FaxAPI.ServerName =something
    FaxAPI.Protocol = RFCOMAPILib.CommunicationProtocolType.cpTCPIP
    FaxAPI.UseNTAuthentication = RFCOMAPILib.BoolType.False
    FaxAPI.AuthorizationUserID = something
    FaxAPI.AuthorizationUserPassword = something
    FaxAPI.OpenServer()
    fFax = FaxAPI.CreateObject(RFCOMAPILib.CreateObjectType.coFax)
    fFax.Attachments.Add(“D:\FilePickupIn\2222222222-20110322142718-01.tif”)
    fFax.HasCoversheet = RFCOMAPILib.BoolType.False
    fFax.ToFaxNumber = something
    fFax.ToName = something
    fFax.Send()
    FaxAPI.CloseServer()
    FaxAPI = Nothing
    fFax = Nothing
    

    如果您遇到任何问题,很乐意提供帮助...

    【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-01-04
    • 2010-11-14
    • 2011-06-07
    • 2017-03-17
    • 1970-01-01
    相关资源
    最近更新 更多