ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

¦p¦ó¨ú¥X«ü©w°£¥~ªº¨ä¥L¤u§@ªí¦WºÙ©O¡H

¦p¦ó¨ú¥X«ü©w°£¥~ªº¨ä¥L¤u§@ªí¦WºÙ©O¡H

¦U¦ì¤j¤j¦n¡G
       
   §Ú¤£·Q¨Ï¥Îif°j°é¨Ó¼g¡A¦Ó¥Hmatch¨ç¼Æ
©Î¬O¨ä¥¦¤è¦¡¨Ó¹F¦¨¤U­±©Ò­zªº±¡§Î¡C        
   §Ú·Q«ü©w¬Y¨Ç¤u§@ªí¨Ã±N¨ä±Æ°£¦b¥~¡C
²{¥Îmatch¤è¦¡«o¦³ªýê¡A¤£ª¾­n¦p¦ó
­×¥¿»yªk¤~¤ñ¸û¦X¾A©O¡H
   

   ³]¦³¤»­Ó¤u§@ªí¨ä¦WºÙ¬°
"aa","bb","cc","dd","ee","ff"

­n¦p¦ó±N¤u§@ªí¦WºÙ"bb","dd","ee"
¦s¤Jar1°}¦C©O¡H

»yªk¦p¤U¡G

Sub aa()
   
    Dim mSht As Worksheet
    Dim ar, ar1()
    Dim s%, s1%
    Dim mStr$
   
    ar = Array("aa", "cc", "ff")
    For Each mSht In Worksheets
        mStr = mSht.Name
        On Error GoTo 10
        s = Application.WorksheetFunction.Match(mStr, ar, 0)
20
        
    Next
        Exit Sub
        
10
        
            ReDim Preserve ar1(s1)
            ar1(s1) = mSht.Name
            s1 = s1 + 1
            GoTo 20
   
End Sub

·P®¦¤j¤j¡I

¥»©«³Ì«á¥Ñ et5323 ©ó 2010-10-17 11:12 ½s¿è

Sub aa()
    Dim mSht As Worksheet
    Dim ar, ar1()
    Dim s%, s1%
    Dim mStr$
   
    On Error Resume Next
    ar = Array("aa", "cc", "ff")
    For Each mSht In Worksheets
        mStr = mSht.Name
        s = Application.WorksheetFunction.Match(mStr, ar, 0)
        If Err.Number <> 0 Then
            ReDim Preserve ar1(s1)
            ar1(s1) = mSht.Name
            s1 = s1 + 1
            Err.Clear
        End If
    Next
End Sub

TOP

ÁÂÁ¤j¤j¡C

³o¥¿¬O¤p§Ì©Ò´Á«Ýªº»yªk¡C
Err.Number ¤]¬O¤p§Ì
¤µ¤Ñ¤~¤F¸Ñ¦p¦¹¦n¥Î©O¡H

·P®¦¤j¤j¡I

TOP

        ÀR«ä¦Û¦b : ¬Ý§O¤H¤£¶¶²´¡A¬O¦Û¤v­×¾i¤£°÷¡C
ªð¦^¦Cªí ¤W¤@¥DÃD