这是我最近写的,用来把数据导入excel并在excel中生成图表的
Dim intCols As Integer
Dim xlapp As New Excel.Application
Dim xlbook As New Excel.Workbook
Dim xlbooktmp As New Excel.Workbook
Dim xlchart As New Excel.Chart
Dim xlsheet As New Excel.Worksheet
Dim strDestination As String
Dim strSource As String
On Error Resume Next
CommonDialog1.ShowSave '设置保存文件路径
strDestination = CommonDialog1.FileName
CommonDialog1.FileName = ""
If strDestination = "" Then Exit Sub
这是我最近写的,用来把数据导入excel并在excel中生成图表的
Dim intCols As Integer
Dim xlapp As New Excel.Application
Dim xlbook As New Excel.Workbook
Dim xlbooktmp As New Excel.Workbook
Dim xlchart As New Excel.Chart
Dim xlsheet As New Excel.Worksheet
Dim strDestination As String
Dim strSource As String
On Error Resume Next
CommonDialog1.ShowSave '设置保存文件路径
strDestination = CommonDialog1.FileName
CommonDialog1.FileName = ""
If strDestination = "" Then Exit Sub