Loading

excel常用操作

计算时间戳
=(A2-70365-19)86400-8*3600

计算回归曲线
斜率=SLOPE(A1:A10,B1:B10)
截距=INTERCEPT(A1:A10,B1:B10)

激活单元格

Sub OpenHprLnks()
Dim i As Integer
On Error Resume Next
For i = 1 To 323
ActiveWorkbook.FollowHyperlink Cells(i, 2).Value, , True
Next
End Sub

添加session
https://blog.csdn.net/biao0309/article/details/90316925

vba入门
https://www.cnblogs.com/wzh313/articles/9737573.hhtml

Private Sub 分拆工作表

Dim sht As Worksheet
Dim MyBook As Workbook
Set MyBook = ActiveWorkbook
For Each sht In MyBook.Sheets
sht.Copy
ActiveWorkbook.SaveAs Filename:=MyBook.Path & "\" & sht.Name, FileFormat:=xlNormal '将工作簿另存为EXCEL默认格式
ActiveWorkbook.Close
Next
MsgBox "文件已经被分拆完毕!"
End Sub
posted @ 2021-07-31 11:01  JJiaa  阅读(135)  评论(0编辑  收藏  举报