请选择 进入手机版 | 继续访问电脑版
查看: 492|回复: 0

[.NET开发] AT指令集发送短信 VB程序

3万

主题

3万

帖子

10万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
100197
发表于 2015-11-23 17:52:15
代码最早来自"江龙"2005年写的,可惜他的网站打不开了。
通过VB控制短信猫发送短信的程序
  1. Attribute VB_Name = "TC35_API"
  2. Public Declare Function timeGetTime Lib "winmm.dll" () As Long
  3. Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long
  4. Public Sub ShowMsg(ByVal s As String)
  5. MsgBox s, vbInformation Or vbOKOnly, "信息提示"
  6. End Sub
  7. Public Function ShowYesNo(s As String, Optional ByVal Title As String = "取消确认") As Boolean
  8. ShowYesNo = (MsgBox(s, vbYesNo Or vbInformation, Title) = vbYes)
  9. End Function
  10. Public Sub PreviewURL(ByVal URL As String)
  11. Call ShellExecute(0, "Open", URL, "", App.Path, 1)
  12. End Sub
复制代码


回复

使用道具 举报