Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Private Sub cbn_RunExtreme_Click()
- WBpath = Application.ActiveWorkbook.Path
- Set checksOutput = CreateObject("Scripting.FileSystemObject")
- Set textFile = checksOutput.OpenTextFile(WBpath & "/checklog" & ".txt", 8, True)
- textFile.Writeline "Checks for extreme small or big values:"
- textFile.Writeline "_______________________________________"
- textFile.Writeline Now()
- '[Writing values to textfile]
- If cbx_OpenLogfile.Value = True Then
- Retry:
- If ItIsARetry Then On Error Resume Next Else On Error GoTo TryAndClose
- Open WBpath & "checklog" & ".txt" For Input As #1
- On Error GoTo 0
- Exit Sub
- TryAndClose:
- Close #1
- ItIsARetry = True
- GoTo Retry
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement