EXCEL§ì¨úCSV¸ê®Æ¨Ã§Y®É§ó·s
- ©«¤l
- 28
- ¥DÃD
- 7
- ºëµØ
- 0
- ¿n¤À
- 43
- ÂI¦W
- 0
- §@·~¨t²Î
- windows7
- ³nÅ骩¥»
- office2010
- ¾\ŪÅv
- 10
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2013-11-8
- ³Ì«áµn¿ý
- 2020-4-9
|
¤£¶}±ÒÀɮפUŪ¨ú¸ê®Æªº¸ô®|/ÀɦW³]©w¬°ÅܼưÝÃD
±ýŪ¨úªºEXCELÀɦW¤¤³£¦³·í¤Ñ¤é´Á(ex:ooxxx1021216.xls)
·Q°µ¤@±i·JÁ`ªí¦s©ñ¦b¥t¤@Ó¸ê®Æ§¨
·JÁ`ªíAÄæ¦ì¬O§Únªº¤é´Á
¥H¤£¶}±ÒÀɮפ覡¨ÓŪ¨ú¸ê®Æ
¦³¸Õ¹Lª½±µ¥Î "µu´ÁªÑÅv§ë¸ê³¡¦ì¤Îµû»ù±±ºÞªí1021216.xls" ¬O§ì¨ì¸ê®Æ
¦ý§ï¦¨" µu´ÁªÑÅv§ë¸ê³¡¦ì¤Îµû»ù±±ºÞªí" & dd & ".xls"
¥ÎÅܼƤ覡´N¤£¦æ
¥X²{n§Ú¿ï¨úÀɮתºµe±
À³¸Ó¬OÅܼƳ]©w¿ù»~
½Ð°Ý
1.ÅܼÆn¦p¦ó³]©w??
2.ÁÙ¦³¨ä¥L§ó¤è«Kªº¤è¦¡¨ÓŪ¨ú¥¼¶}±ÒÀɮ׸ê®Æ??
Sub checkclosedfile1()
Dim strpath As String, strfile As String
Dim strsheet As String, strresult As String
strpath = "X:\·ºÞ³øªí\µu´ÁªÑÅv§ë¸ê³¡¦ì¤Îµû»ù±±ºÞªí"
strfile = "µu´ÁªÑÅv§ë¸ê³¡¦ì¤Îµû»ù±±ºÞªí1021202.xls"
strsheet = "¥þ¤½¥qI"
strresult = getcellvalue(strpath, strfile, strsheet, "i1")
Cells(2, 2) = strresult
End Sub
Public Function getcellvalue(strpath As String, strfile As String, strsheet As String, stra1 As String)
getcellvalue = ExecuteExcel4Macro("'" & "[" & strfile & "]" & strsheet & "'!" & Range(stra1).Address(, , xlR1C1))
End Function |
|
¤p¤Hª«
|
|
|
|
|
- ©«¤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
|
¦^´_ 1# jasonwu0114
ªþ¤W¤£¦æªºµ{¦¡½X¬Ý¬Ý |
|
|
|
|
|
|
- ©«¤l
- 28
- ¥DÃD
- 7
- ºëµØ
- 0
- ¿n¤À
- 43
- ÂI¦W
- 0
- §@·~¨t²Î
- windows7
- ³nÅ骩¥»
- office2010
- ¾\ŪÅv
- 10
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2013-11-8
- ³Ì«áµn¿ý
- 2020-4-9
|
¥»©«³Ì«á¥Ñ jasonwu0114 ©ó 2013-12-17 16:29 ½s¿è
§ä¨ì¤ñ¸û²³æ¼gªk
·Q½Ð±Ð
°²¦psheet1AÄ榳¤@¨Ç¤é´Á
¬O§Ún§ìªºÀɮצWºÙ¤@³¡¤À(¬õ¦r³¡¤À)
[IRS¥æ©ö³¡¦ìµû»ùªí1021216.xls]
¦pªGn§â¸ê®Æ§ì¦^©ñ¦bBÄæn¦p¦ó¼g¦p¦ó³]©wÅܼÆ??
¥t¥~
¤@¦¸¥u¯à§ì¤@ÓÄæ¦ì¶Ü??
Sub nn()
[A1] = ExecuteExcel4Macro("'X:\·ºÞ³øªí\§Q²v¥æ´«³¡¦ìµû»ùªí\[IRS¥æ©ö³¡¦ìµû»ùªí1021216.xls]³¡¦ìµû»ùªí'!R1C13")
End Sub |
|
¤p¤Hª«
|
|
|
|
|
- ©«¤l
- 28
- ¥DÃD
- 7
- ºëµØ
- 0
- ¿n¤À
- 43
- ÂI¦W
- 0
- §@·~¨t²Î
- windows7
- ³nÅ骩¥»
- office2010
- ¾\ŪÅv
- 10
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2013-11-8
- ³Ì«áµn¿ý
- 2020-4-9
|
¥»©«³Ì«á¥Ñ jasonwu0114 ©ó 2013-12-18 11:35 ½s¿è
¤£¦n·N«ä¤w¸Ñ¨M¦p¤U
½Ð°ÝÁÙ¥i¥H¼gªº§óSMART¶Ü??
¥t¥~yy = "'X:\·ºÞ³øªí\¥æ´«³¡¦ìµû»ùªí\[IRS³¡¦ìµû»ùªí" & kk & ".xls]³¡¦ìµû»ùªí'!R1C13"
R1C13³o¸Ì¥u¯à¬O³æ¤@Äæ¦ì¶Ü??
Sub nn4()
Dim yy As String
Dim kk As Range
Set kk = Sheets("¤u§@ªí1").Range("A3")
Do While kk <> ""
yy = "'X:\·ºÞ³øªí\¥æ´«³¡¦ìµû»ùªí\[IRS³¡¦ìµû»ùªí" & kk & ".xls]³¡¦ìµû»ùªí'!R1C13"
kk.Offset(0, 3) = ExecuteExcel4Macro(yy)
Set kk = kk.Offset(1)
Loop
End Sub |
|
¤p¤Hª«
|
|
|
|
|
- ©«¤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
|
¥»©«³Ì«á¥Ñ stillfish00 ©ó 2013-12-18 12:45 ½s¿è
¦^´_ 4# jasonwu0114 - Sub nn4()
- With Sheets("¤u§@ªí1")
- With .Range(.[D3], .Cells(.Rows.Count, "D").End(xlUp))
- .FormulaR1C1 = "='X:\·ºÞ³øªí\¥æ´«³¡¦ìµû»ùªí\[IRS³¡¦ìµû»ùªí" & .Parent.[A3].Value & ".xls]³¡¦ìµû»ùªí'!R1C13"
- .Value = .Value
- End With
- End With
- End Sub
½Æ»s¥N½X |
|
|
|
|
|
|
- ©«¤l
- 28
- ¥DÃD
- 7
- ºëµØ
- 0
- ¿n¤À
- 43
- ÂI¦W
- 0
- §@·~¨t²Î
- windows7
- ³nÅ骩¥»
- office2010
- ¾\ŪÅv
- 10
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2013-11-8
- ³Ì«áµn¿ý
- 2020-4-9
|
¦^´_ 5# stillfish00
¼F®`¼F®`
¤S¾Ç¨ì¦n´X©Û
¥i¬OÁÙ¦³¤@ÂI°ÝÃD
D3~8Äæ¦pªG쥻¬OªÅ®æ°õ¦æ«áD1~D3·|¶ñ¥HA3¬°°Ñ¼Æ§ä¨ìªº¸ê®Æ
¦pªG¦³¼Æ¦r°õ¦æ«áD3~D8·|¶ñ¥HA3¬°°Ñ¼Æ§ä¨ìªº¸ê®Æ
n§ïþ??
ÁÙ¦³ With .Range(.[D3], .Cells(.Rows.Count, "D").End(xlUp)) ªº·N«ä??
|
|
¤p¤Hª«
|
|
|
|
|
- ©«¤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
|
¥»©«³Ì«á¥Ñ stillfish00 ©ó 2013-12-18 18:30 ½s¿è
¦^´_ 6# jasonwu0114 - Sub nn4()
- With Sheets("¤u§@ªí1")
- With .Range(.[A3], .Cells(.Rows.Count, "A").End(xlUp)).offset(,3)
- .FormulaR1C1 = "='X:\·ºÞ³øªí\¥æ´«³¡¦ìµû»ùªí\[IRS³¡¦ìµû»ùªí" & .Parent.[A3].Value & ".xls]³¡¦ìµû»ùªí'!R1C13"
- .Value = .Value
- End With
- End With
- End Sub
½Æ»s¥N½X .Rows.Count : Excel³Ì¤j¦æ¼Æ
.Cells(.Rows.Count, "A") : AÄæ³Ì¤U±¤@®æ
.Cells(.Rows.Count, "A").End(xlUp) : ±qAÄæ³Ì¤U±¤@®æ©¹¤W§ä¨ì¦³¸ê®ÆªºÀx¦s®æ
.Range(.[A3], .Cells(.Rows.Count, "A").End(xlUp)) : ±qA3¨ìAÄæ³Ì«á¤@µ§¸ê®Æ§Î¦¨ªº½d³ò
.Range(.[A3], .Cells(.Rows.Count, "A").End(xlUp)).offset(,3) : ±qA3¨ìAÄæ³Ì«á¤@µ§¸ê®Æ§Î¦¨ªº½d³ò¡A³o½d³ò¦A©¹¥k²¾°Ê¤TÄæ |
|
|
|
|
|
|
- ©«¤l
- 28
- ¥DÃD
- 7
- ºëµØ
- 0
- ¿n¤À
- 43
- ÂI¦W
- 0
- §@·~¨t²Î
- windows7
- ³nÅ骩¥»
- office2010
- ¾\ŪÅv
- 10
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2013-11-8
- ³Ì«áµn¿ý
- 2020-4-9
|
¦^´_ 7# stillfish00
¤£¦n·N«äÁÙn¦A³Â·Ð
°õ¦æ«áÁÙ¬O¥HA3¬°°Ñ¼Æ¥h§ì¸ê®Æ- .FormulaR1C1 = "='X:\·ºÞ³øªí\¥æ´«³¡¦ìµû»ùªí\[IRS³¡¦ìµû»ùªí" & .Parent.[A3].Value & ".xls]³¡¦ìµû»ùªí'!R1C13"
½Æ»s¥N½X À³¸Ó¬On§ï³o.Parent.[A3]¶Ü
¦p¦ó§ï??
·P®¦!! |
|
¤p¤Hª«
|
|
|
|
|
- ©«¤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
|
¦^´_ 8# jasonwu0114
§Ú¦n¹³»~·|§Aªº·N«ä¤F¡A¬O³o¼Ë¶Ü?- Sub nn5()
- Dim x
- With Sheets("¤u§@ªí1")
- For Each x In .Range(.[A3], .Cells(.Rows.Count, "A").End(xlUp)).Offset(, 3)
- x.Value = ExecuteExcel4Macro("'X:\·ºÞ³øªí\¥æ´«³¡¦ìµû»ùªí\[IRS³¡¦ìµû»ùªí" & x.Offset(, -3).Value & ".xls]³¡¦ìµû»ùªí'!R1C13")
- Next
- End With
- End Sub
½Æ»s¥N½X |
|
|
|
|
|
|
- ©«¤l
- 28
- ¥DÃD
- 7
- ºëµØ
- 0
- ¿n¤À
- 43
- ÂI¦W
- 0
- §@·~¨t²Î
- windows7
- ³nÅ骩¥»
- office2010
- ¾\ŪÅv
- 10
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2013-11-8
- ³Ì«áµn¿ý
- 2020-4-9
|
¦^´_ 9# stillfish00
stillfish00¤j¤j
¬Oªº¨S¿ù
«D±`·PÁÂ
¾Ç¨ì¤£¤ÖªF¦è |
|
¤p¤Hª«
|
|
|
|
|