- ©«¤l
- 5923
- ¥DÃD
- 13
- ºëµØ
- 1
- ¿n¤À
- 5986
- ÂI¦W
- 0
- §@·~¨t²Î
- win10
- ³nÅ骩¥»
- Office 2010
- ¾\ŪÅv
- 150
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW°ò¶©
- µù¥U®É¶¡
- 2010-5-1
- ³Ì«áµn¿ý
- 2022-1-23
|
¦^´_ 1# openpc - Option Explicit
- Sub Ex()
- Dim S As Workbook, xlPath As String
- xlPath = CurDir 'CurDir ¨ç¼Æ ¶Ç¦^¤@Ó Variant (String)¡A¥Î¨Ó¥Nªí¥Ø«eªº¸ô®|¡C
- Application.Workbooks.Open "a.xls" '¶}±Ò¥Ø«eªº¸ô®|ªºÀÉ®×
- 'Workbooks.Open xlPath & "a.xls" '¶}±Ò«ü©w¸ô®|ªºÀÉ®×
- 'Set S = Workbooks.Open("a.xls") '«ü©w¨ìÅܼÆn( )
- MsgBox ActiveWorkbook.FullName
- End Sub
- '¦pªG©Ò¦³EXCELÀɮ׳£©ñ¦b¬Û¦Pªº¸ô®|(¥Ø¿ý¡^¤U¡A¥i¤£¥i¥H¦³¤°»ò²«Kªº¼gªk?
- Sub Ex1()
- Dim xlPath As String
- xlPath = "D:\test\"
- ChDrive Mid(xlPath, 1, 1) '²¾°Ê(ºÏºÐ¾÷)
- ChDir xlPath '²¾°Ê(¥Ø¿ý¡^
- Workbooks.Open "a.xls" '¶}±Ò¥Ø«eªº¸ô®|ªºÀÉ®×
- End Sub
½Æ»s¥N½X |
|