1.VB 读åExcelçå
容
VB 读åExcelçå 容
'以ä¸æ¯æºä»£ç ï¼
'å¼ç¨Microsoft Excel .0 Object Library
'Excelæ件æ¾äºDçç®å½ä¸ï¼å称为ï¼my.xls
Private Sub Command1_Click()
Dim A() As String
Dim i As Integer
Dim xlsApp As Excel.Application
Dim xlsWorkbook As Excel.Workbook
Dim xlssheet As Excel.Worksheet
Set xlsApp = CreateObject("Excel.Application")
Set xlsWorkbook = xlsApp.Workbooks.Open("D:\my.xls")
xlsApp.Visible = True
xlsApp.Range("A1").Select
For i = 1 To
A(i) = xlsApp.ActiveCell.Offset(0, i - 1).Value
Print i;
Print " ";
Print A(i)
Next i
Set xlssheet = Nothing
Set xlsWorkbook = Nothing
Set xlsApp = Nothing
End Sub
泌尿醫點名「排尿4病症」是身體警示信號! 量太少快就醫
跟你吃的不同? 必比登推介「蚵仔煎照」掀熱議
陳信瑜涉貪請辭已獲准 將於8/28生效
林信吾狠殺2警涉3重罪遭聲押 今下午3點開羈押庭
危地馬拉當選總統因國會爭議推遲任職
护航“开学季” 山东省市场监管系统在行动