Merck & Co. said on Tuesday it agreed to pay $58 million to settle allegations that its ads for the once-popular painkiller Vioxx deceptively played down the health risks in 29 states, including the District of Columbia.

The settlement responds to allegations that Merck deceived the consumers with an advertising campaign in 1999 that misrepresented the safety and improperly concealed the increased risks linked to Vioxx.

The drug was withdrawn in 2004 after patients that took the drug showed increased risks of heart attacks and strokes.

This settlement addresses all of our concerns and will restrict Merck's ability to deceptively promote any of their products. said Tom Corbett in a statement on Tuesday.

Under the agreement, Merck is also urged to review all TV advertising campaigns to the U.S. Food and Drug Administration.

Shares of Merck were lastly trading down 0.07 percent at $39.98 in composite Tuesday trading on the New York stock Exchange.