MathGroup Archive 2006

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: How to determine whether a message has been switched

  • To: mathgroup at smc.vnet.net
  • Subject: [mg71548] Re: How to determine whether a message has been switched
  • From: "Philipp" <Philipp.M.O at gmail.com>
  • Date: Wed, 22 Nov 2006 05:22:28 -0500 (EST)
  • References: <200611190610.BAA23575@smc.vnet.net><ejrn2r$98u$1@smc.vnet.net>

David,

It is documented, although in a place that is possibly not the best,
not under $Off or even Off, but under Built-in Functions->Messages; the
second bullet point states

· Messages that have been switched off using Off are enclosed in $Off.

Cheers,
Philipp

David Bailey wrote:
> Carl Woll wrote:
> > Andrew Moylan wrote:
> >
> >> Hi all,
> >>
> >> When writing algorithms, I sometimes decide to disable a particular
> >> message using the function Off[]. At the end of my routine, I re-enable
> >> the message using the function On[].
> >>
> >> Unfortunantely, if the message in question has already been turned off
> >> (by some other function, for example), then my code will have the
> >> unfortunate side-effect of switching it back on. What I really want is
> >> to disable the message for the duration of my routine, and then set it
> >> back to its original state at the end of my routine.
> >>
> >> Thus: Is there some way to determine whether a message has been
> >> switched Off[] (or On[])?
> >>
> >> Cheers,
> >> Andrew
> >>
> >>
> > Look at the message:
> >
> > Off[General::spell1]
> >
> > In[2]:=
> > General::spell1
> > Out[2]=
> > $Off[Possible spelling error: new symbol name "`1`" is similar to existing \
> > symbol "`2`".]
> >
> > Messages that have been turned off are wrapped in $Off.
> >
> > Carl Woll
> > Wolfram Research
> >
> Carl,
>
> Don't you think information like that should be documented! If you look
> up the symbol $Off, it is there, but with no help information at all!
> 
> David Bailey
> http://www.dbaileyconsultancy.co.uk


  • Prev by Date: Re: ComplexityFunction affects set of transformations tried by Simplify
  • Next by Date: Re: symbolic solution of ODE
  • Previous by thread: Re: Re: How to determine whether a message has been switched
  • Next by thread: plot question