[英]How to get the recordset data from Word VBA to excel sheet?
我是 VBA 的新手,為了滿足部分要求,我需要使用 Word 宏從 SQL 表到 Excel 表中獲取數據。 我嘗試過了
這部分可能是您需要的關鍵部分(但您也可能需要之前的部分來處理日期值和其他更復雜的數據類型:
' Transpose and Copy the array to the worksheet,
' starting in cell A2
xlWs.Cells(2, 1).Resize(recCount, fldCount).Value = _
TransposeDim(recArray)
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.