如何用vb发传真,问题解决必送分!!!

jxnetinfo 2003-09-29 08:41:56
如何用vb发传真,问题解决必送分!!!
...全文
29 6 打赏 收藏 转发到动态 举报
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
kmzs 2003-10-21
  • 打赏
  • 举报
回复
直接使用,不用引用吧?
imur 2003-10-21
  • 打赏
  • 举报
回复
学习
lihonggen0 2003-10-12
  • 打赏
  • 举报
回复
用windows 2000自带的Faxcom
lihonggen0 2003-10-12
  • 打赏
  • 举报
回复
Attribute VB_Name = "MdlFax"

Option Explicit

Private FS As New FAXCOMLib.FaxServer

Private FD As New FAXCOMLib.FaxDoc

Private Const MAX_COMPUTERNAME_LENGTH As Long = 31

Private Declare Function GetComputerName Lib "kernel32" Alias "GetComputerNameA" (ByVal lpBuffer As String, nSize As Long) As Long

' ·¢?í′???·?·¨£?′?è?ò???·¢?í???t?·??£??1óD??±êo???

' Dim tmpFaxFile As String

' tmpFaxFile = App.Path & "\LastFax.doc"

' m_CrReport.ExportOptions.FormatType = crEFTExactRichText

' m_CrReport.ExportOptions.DestinationType = crEDTDiskFile

' m_CrReport.ExportOptions.DiskFileName = tmpFaxFile

' m_CrReport.DisplayProgressDialog = False

' m_CrReport.Export False

' frmFax01.SendDoc = tmpFaxFile

' frmFax01.ShowForm





Public Function SendFax(SendDocPath As String, SendNumber As String) As String

On Error GoTo Err_Conn

FS.Connect (ComputerName) ' My Computer's name

On Error GoTo Err_Catch

Set FD = FS.CreateDocument(SendDocPath)

FD.FileName = SendDocPath

FD.FaxNumber = SendNumber ' Fax number

FD.DisplayName = SendNumber

FD.DiscountSend = 0

FD.SendCoverpage = 0

FD.Send

Err_Catch:

GoTo ExitFunc

Err_Conn:

GoTo ExitFunc

ExitFunc:

If Err.Description <> "" Then

SendFax = Err.Description

Else

SendFax = "0"

End If

On Error Resume Next

FS.Disconnect

End Function

Public Function Init() As String

' 3?ê?

On Error GoTo Err_Catch

FS.Connect (ComputerName) ' My Computer's name

Init = "0"

GoTo ExitFunc

Err_Catch:

Init = "3?ê?′????ú꧰ü,??è·?¨ê?·?×°óD′????ú"

Debug.Print Err.Description

ExitFunc:



End Function

Private Property Get ComputerName() As String

Dim dwLen As Long

Dim strString As String

dwLen = MAX_COMPUTERNAME_LENGTH + 1

strString = String(dwLen, " ")

GetComputerName strString, dwLen

strString = Left(strString, dwLen)

End Property

rainstormmaster 2003-10-12
  • 打赏
  • 举报
回复
http://www.china-askpro.com/msg7/qa97.shtml
xiaohuangtao 2003-10-12
  • 打赏
  • 举报
回复
超OUTLOOK软件(正式版SmartMail1.0免费提供源码(最新版))
运行演示图:http://bbs.2ccc.com/uploads/huangtao/运行效果图.jpg
下载地址:http://bbs.2ccc.com/uploads/huangtao/smartmail1.0.rar
源码 放送

1,451

社区成员

发帖
与我相关
我的任务
社区描述
VB 控件
社区管理员
  • 控件
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧