IfExist / IfNotExist

ÆÄÀÏÀ̳ª Æú´õÀÇ Á¸Àç ¿©ºÎ¸¦ Á¡°ËÇÕ´Ï´Ù.

IfExist, FilePattern
IfNotExist, FilePattern
AttributeString := FileExist(FilePattern)

¸Å°³º¯¼ö

FilePattern

Á¡°ËÇÒ °æ·Î, ÆÄÀÏÀ̸§ ¶Ç´Â ÆÄÀÏ ÆÐÅÏ. Àý´ë °æ·Î¸¦ ÁöÁ¤ÇÏÁö ¾ÊÀ¸¸é FilePatternÀº %A_WorkingDir%¿¡ ÀÖÀ» °ÍÀ̶ó°í °£Áֵ˴ϴÙ.

°ü·Ã Ç׸ñ

FileExist(), ºí·Ï, Else, File-ȸµ¹ÀÌ

¿¹Á¦

IfExist, D:\
    MsgBox, µå¶óÀ̺갡 Á¸ÀçÇÕ´Ï´Ù.
IfExist, D:\Docs\*.txt
    MsgBox, Àû¾îµµ ÇϳªÀÇ .txt ÆÄÀÏÀÌ Á¸ÀçÇÕ´Ï´Ù.
IfNotExist, C:\Temp\FlagFile.txt
    MsgBox, ¸ñÇ¥ ÆÄÀÏÀÌ Á¸ÀçÇÏÁö ¾Ê½À´Ï´Ù.