Office中国论坛/Access中国论坛
标题:
如何获得当前Word 表格行数
[打印本页]
作者:
骷髅头
时间:
2004-7-20 21:26
标题:
如何获得当前Word 表格行数
Dim DocApp As Word.Application '声明类型
Dim aDoc As Word.Document
Dim DocTable As Word.Table
Dim mReadPathStr As String
mReadPathStr = "C:\Documents and Settings\Administrator\桌面\Test\test.dot"
Set DocApp = CreateObject("Word.Application")
DocApp.Documents.Open (mReadPathStr)
Set aDoc = DocApp.Documents(mReadPathStr)
MsgBox aDoc.Tables(2).Rows <=====出错 如何获得当前Word 表格行数
DocApp.Quit
Set DocApp = Nothing
aDoc.Close
Set aDoc = Nothing
[此贴子已经被作者于2004-7-20 13:26:36编辑过]
作者:
xinbao
时间:
2004-7-21 02:51
不错, 收到
作者:
骷髅头
时间:
2004-7-21 21:34
MsgBox aDoc.Tables(2).Rows.Count
欢迎光临 Office中国论坛/Access中国论坛 (http://www.office-cn.net/)
Powered by Discuz! X3.3