R
Ralph Shnelvar
[Note: parts of this message were removed to make it a legal post.]
Let's say I'm running rubyw and a RunTimeError is raised ...
and I'm using FXRuby (which is tangential to this question) ...
and I want to put up a errorbox ...
But I want to capture the error message that would normally go to stdout, i.e. the call stack ...
How would I capture the call stack to a string in a raised exception?
- - -
begin
raise RuntimeError, "Something bad happened"
rescue
# What do I do here?
end
- - -
Let's say I'm running rubyw and a RunTimeError is raised ...
and I'm using FXRuby (which is tangential to this question) ...
and I want to put up a errorbox ...
But I want to capture the error message that would normally go to stdout, i.e. the call stack ...
How would I capture the call stack to a string in a raised exception?
- - -
begin
raise RuntimeError, "Something bad happened"
rescue
# What do I do here?
end
- - -