ADO¦s¨ú¸ê®Æ®w .RecordCountªð¦^È°ÝÃD
- ©«¤l
- 1018
- ¥DÃD
- 15
- ºëµØ
- 0
- ¿n¤À
- 1058
- ÂI¦W
- 0
- §@·~¨t²Î
- win7 32bit
- ³nÅ骩¥»
- Office 2016 64-bit
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ®ç¶é
- µù¥U®É¶¡
- 2012-5-9
- ³Ì«áµn¿ý
- 2022-9-28
|
ADO¦s¨ú¸ê®Æ®w .RecordCountªð¦^È°ÝÃD
¤£¦n·N«ä , ·Q½Ð±Ð¤@¤U§Ú¦bExcel VBA¸Ì¥ÎADODB¦s¨úAccess¸ê®Æ®w
¥N½X¦p¤U , ¥i¬ORecordCountªð¦^È«o¬O-1¦Ó¤£¬O¬d¸ß¨ìªºµ§¼Æ
½Ð°Ýn¦p¦óקï¤~¹ï?- Sub test()
- Dim adoConnect As New ADODB.Connection
- Dim oRS As New ADODB.Recordset
-
- With adoConnect
- .Provider = "Microsoft.ACE.OLEDB.12.0"
- .Mode = adModeReadWrite
- .ConnectionTimeout = 15
- .Open "G:\stock\DB_Stock_0926.accdb"
- End With
- Set oRS = adoConnect.Execute("SELECT * FROM MyTable")
- Debug.Print oRS.RecordCount
-
- adoConnect.Close
- Set oRS = Nothing
- Set adoConnect = Nothing
- End Sub
½Æ»s¥N½X |
|
|
|
|
|
|
- ©«¤l
- 1018
- ¥DÃD
- 15
- ºëµØ
- 0
- ¿n¤À
- 1058
- ÂI¦W
- 0
- §@·~¨t²Î
- win7 32bit
- ³nÅ骩¥»
- Office 2016 64-bit
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ®ç¶é
- µù¥U®É¶¡
- 2012-5-9
- ³Ì«áµn¿ý
- 2022-9-28
|
¦^´_ 2# kimbal
«z ~ ÁÂÁ , ³o¼ËÈ´N¥¿½T¤F:D |
|
|
|
|
|
|
- ©«¤l
- 472
- ¥DÃD
- 5
- ºëµØ
- 0
- ¿n¤À
- 485
- ÂI¦W
- 0
- §@·~¨t²Î
- Windows
- ³nÅ骩¥»
- MS Office
- ¾\ŪÅv
- 100
- ©Ê§O
- ¨k
- ¨Ó¦Û
- »´ä
- µù¥U®É¶¡
- 2010-7-4
- ³Ì«áµn¿ý
- 2014-12-28
|
¦^´_ 1# stillfish00
¸Õ¸Õ¦h¥[¤@¦æ
.CursorLocation = adUseClient
¦b.Provider ¤§¤U |
|
|
|
|
|
|