關鍵功能
- 批量收郵件及打印
- 批量發送郵件及有關 I / O 問題
- 網頁操作
Reference
Excel+VBA常用功能(三):批量发送邮件 - 黄晨的文章 - 知乎
使用Excel+VBA对网页进行操作 - 黄晨的文章 - 知乎
Excel Home 論壇
With CreateObject("internetexplorer.application").Visible = True.Navigate "https://www.baidu.com/s?wd=扯乎"'关闭网页' .QuitEnd With
P01) 保存outlook里email的附件
Private Sub CommandButton1_Click()On Error Resume NextDim myolapp As New Outlook.ApplicationSet fs = CreateObject("Scripting.FileSystemObject")If Not fs.FolderExists("c:\µÁ◊”” º˛") Then fs.CreateFolder ("c:\µÁ◊”” º˛")Set myNameSpace = myolapp.GetNamespace("MAPI")Set myfolder = myNameSpace.GetDefaultFolder(olFolderInbox)For i = 1 To myfolder.Items.CountSet mymailitem = myfolder.Items(i)With mymailitemSet myAttachments = mymailitem.Attachmentspara = myAttachments.Item(1).DisplayNamemyAttachments.Item(1).SaveAsFile "c:\µÁ◊”” º˛\" + IIf(IsNull(myAttachments.Item(1).DisplayName), i, myAttachments.Item(1).DisplayName)End WithNextMsgBox "±æ≥ÖÚ÷¥––Õͱœ£°«ÎµΩƒø¬º÷–≤Ïø¥∏Ωº˛±£¥Ê«Èøˆ°£", vbDefaultButton1, "Loadhigh”—«È÷–—"UserForm1.HideEnd Sub
