Stop Function Exectution With Formatted Message
Arguments
- x
Error message, possibly containing percentage placeholders, passed as argument
fmt
tosprintf
- ...
as many values as referenced with percentage placeholders in the error message
- call.
logical, indicating if the call should become part of the error message.
Examples
try(stopFormatted(
"Hi, %s, the program fails for the %d-th time.", "Dexter", 1000
))
#> Error : Hi, Dexter, the program fails for the 1000-th time.