# How to save numbers that are in Mathematica messages

I have a program that calls FindDistributionParameters and I get the Mathematica message FindMaximum::eit each time I call the function.

The message is FindMaximum::eit: The algorithm does not converge to the tolerance of _4.641588833612792*^-9_ in 517 iterations. The best estimated solution, with feasibility residual, KKT residual, or complementary residual of {8.785431001660695650243387×10-19,7.654089593359381289428268×10-7,3.755486893336661804848494×10-19}, is returned. 

I want to save the numbers in the messages, so I setup a list to hold the messages as follows: AppendTo[messagelist, {General::eit}];

This saves the following, with none of the numbers in the original message: The algorithm does not converge to the tolerance of 1 in 2 iterations. The best estimated solution, with feasibility residual, KKT residual, or complementary residual of 3, is returned.

How can I access the numbers in the message and save them to a list or something else?

Secondarily, is there a way to increase the number of iterations in FindDistributionParameters?

-

General::eit is simply the format string for the message itself. There is MessageList[n] which gives the names of all messages output during the evaluation of input line n but that doesn't get you any further.
Defining a value for \$MessagePrePrint would be the way to do this, see the second Scope example using Block, Reap and Sow in the documentation, but rather easier is to simply copy and paste the numbers from the displayed message.
FindDistributionParameters[{1.5, 2.8, 4.3, .5}, LaplaceDistribution[μ, σ],
`