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

«ö¶s¨¾§b¸Ë¸m»s§@

«ö¶s¨¾§b¸Ë¸m»s§@

½Ð°Ý¦U¦ì«e½ú¡A
¥Ø«e¤p§Ì°µ¤F¤@­ÓUserform ¤è«K¸ê®Æ¿é¤J®É¥i¥H°µ¸ê®Æ¤ÀªR

¦ý¬O¤p§Ì¤£ª¾¹D­n¦p¦óÅý§O¤H©ó©|¥¼¶}±Ò¥ÀÀÉ(¥t¤@­ÓÀÉ®×)®É ¦pªG¿ù»~ÂIÀ»¨ì«ö¶s ³o¨Ç«ö¶s·|Åã¬O¿ù»~°T®§"±z©|¥¼¶}±Ò¥ÀÀÉ"    ¬Omsgbox§Î¦¡ªº
¦Ó¤£¬O¶]¥X°õ¦æ¿ù»~©Îµ{¦¡½X¿ù»~¥²¶·°»¿ù©ÎÃö³¬ªº°T®§
½Ð°Ý­n¦p¦ó¼g©O?

¬ã¨s«Ü¤[´N¬OµLªk¼g¥X¨Ó³o­Ó°j°é ÁٽЫe½ú­Ì½ç±Ð

¬Û¹ï²³æ¤èªk¡G

Sub ÀË´úÀɮ׶}±Ò()
If TestBookOpen("abc.xls") = "" Then MsgBox "ÀÉ®×¥¼¶}±Ò"
End Sub

ÂŦâ¦r§ï¦¨­nÀË´úªº¡eÀɦW.°ÆÀɦW¡f

¼Ò²Õ¤º¦@¥Î¦Û­q¨ç¼Æ¡G
Function TestBookOpen(BookName$) As String
On Error Resume Next
TestBookOpen = Workbooks(BookName).Name
End Function

TOP

¦^´_ 2# ­ã´£³¡ªL

·PÁ«e½úªº´£ÂI¡A§Ú¥ß¨è¸Õ¬Ý¬Ý!@@

TOP

¦^´_ 2# ­ã´£³¡ªL

«e½ú±z¦n  §Ú­è­è´ú¸Õ¹L«á  ÁöµM¶]¥X©|¥¼¶}±ÒÀɮתºÄµ§iµ¡ ¬O¥¿½Tªº
¦ý¬O±µµÛ´NÁÙ¬O·|¥X²{¦p¤Uªºµe­±


­n¦p¦óÅý«ö¶s«ö§¹¤§«á

1.¦pªG¨S¦³¶}±ÒÀɮ׫h·|Åã¥Ü¨S¦³¶}±ÒÀÉ®×
2.¦pªG¶}±ÒÀɮפF´N·|¤£Åã¥Ü¨S¦³¶}±ÒÀÉ®×
3. ¦p¦ó¤£·|¸õ¥X¦p¤W¹ÏªºÄµ§i ¥u·|¥X²{¨S¦³¶}±ÒÀÉ®×µøµ¡

Àµ½Ð«e½ú½ç±Ð

TOP

¦^´_ 4# chaoyiho


If TestBookOpen("abc.xls") = "" Then MsgBox "ÀÉ®×¥¼¶}±Ò" :Exit Sub '¸õ¥Xµ{§Ç

TOP

¦^´_ 5# ­ã´£³¡ªL

·PÁª©¥D  ¤w¸g¸Ñ¨M¤F!!!


    ¸U¤À·PÁÂ!!

TOP

        ÀR«ä¦Û¦b : ÀR§¤±`®¦¤v¹L¡B¶¢½Í²ö½×¤H«D¡C
ªð¦^¦Cªí ¤W¤@¥DÃD