LibreOffice 24.8 Help
ํ๋ก๊ทธ๋จ ์คํ ๋์ค์ ๋ฐ์ํ ์ค๋ฅ๋ฅผ ์๋ณํ๋ ์ค๋ฅ ์ฝ๋๋ฅผ ํ์ํฉ๋๋ค.
Err
Integer
Err ํจ์๋ ์ค๋ฅ์ ์์ ์์ ์ ํ์ธํ๊ธฐ ์ํด ์ค๋ฅ ์ฒ๋ฆฌ ๋ฃจํด์ ์ฌ์ฉ๋ฉ๋๋ค.
Sub ExampleError
on error goto ErrorHandler REM Set up error handler
Dim iVar as Integer
Dim sVar As String
REM Error occurs due to non-existent file
iVar = Freefile
Open "\file9879.txt" for Input as #iVar
Line Input #iVar, sVar
Close #iVar
Exit Sub
ErrorHandler:
MsgBox "Error " & Err & ": " & Error$ + chr(13) + "At line : " + Erl + chr(13) + Now , 16 ,"an error occurred"
End Sub