- ©«¤l
- 4901
- ¥DÃD
- 44
- ºëµØ
- 24
- ¿n¤À
- 4916
- ÂI¦W
- 255
- §@·~¨t²Î
- Windows 7
- ³nÅ骩¥»
- Office 20xx
- ¾\ŪÅv
- 150
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥x¥_
- µù¥U®É¶¡
- 2010-4-30
- ³Ì«áµn¿ý
- 2024-11-25
|
¥»©«³Ì«á¥Ñ Hsieh ©ó 2012-3-21 22:35 ½s¿è
¦^´_ 1# a703130
§Aªº¥Dn¥\¯à¬OnŪ¨úTest.iniÀɮפº®e¨ìTest¤u§@ªíªºA:CÄæ¶Ü?
ÁÙ¬On¼g¤J¤u§@ªíDATAªºEÄ檺È?
¥H¼g¤JData¤u§@ªíEÄ欰¨Ò- Sub ghost()
- Set d = CreateObject("Scripting.Dictionary")
- fs = ThisWorkbook.Path & "\Test.ini"
- r = 1
- Open fs For Input As #1
- Do While Not EOF(1) ' °õ¦æ°j°éª½¨ìÀɧÀ¬°¤î¡C
- Line Input #1, TextLine ' Ū¤J¤@¦æ¸ê®Æ¨Ã±N¤§«ü©wµ¹ÅܼơC
- ar = Split(TextLine, Chr(9)) ' ¼g¤J°}¦C¡C
- If ar(1) = "" Then
- mystr = ar(0)
- Else
- d(mystr & ar(0)) = ar(2)
- End If
- Loop
- Close #1 ' Ãö³¬ÀɮסC
- With Sheets("Data")
- For Each a In .Range(.[D2], .[D2].End(xlDown))
- mystr = "[" & Application.Lookup("ùÕ", .Range(.[B2], a.Offset(, -2))) & "]"
- a.Offset(, 1) = d(mystr & a)
- Next
- End With
- End Sub
½Æ»s¥N½X |
|