"The Da Vinci Code" author Dan Brown and his ex-wife have agreed to settle a lawsuit in which she alleged he led a secret life during their marriage that included several affairs.

The couple agreed to voluntarily dismiss the lawsuit and "any and all claims and counterclaims in this matter," according to court papers filed Monday in a New Hampshire court.

"Blythe Brown and Dan Brown have reached an amicable resolution of their disagreements, and will have no further comment," Blythe Brown's attorney Harvey Wolkoff said in a statement. "They request that their desire for privacy and closure be respected."

In this Oct. 10, 2016 file photo, author Dan Brown is seen in Berlin, Germany. The ‘DaVinci Code’ author, a resident of New Hampshire, has settled a lawsuit that was filed by his ex-wife, Blythe Brown, over allegations that he led a secret life during their marriage that included several affairs, according to court papers filed Monday, Dec 27, 2021.

In this Oct. 10, 2016 file photo, author Dan Brown is seen in Berlin, Germany. The ‘DaVinci Code’ author, a resident of New Hampshire, has settled a lawsuit that was filed by his ex-wife, Blythe Brown, over allegations that he led a secret life during their marriage that included several affairs, according to court papers filed Monday, Dec 27, 2021. (AP Photo/Markus Schreiber, File)

No further details on the settlement were provided.

ARNOLD SCHWARZENEGGER AND MARIA SHRIVER ARE OFFICIALLY DIVORCED

In her lawsuit filed last year, Blythe Brown called her ex-husband’s behavior "unlawful and egregious" and accused the bestselling author of secretly diverting funds to pay for gifts to an unnamed horse trainer.

Blythe Brown also claimed credit for inspiring much of his work and coming up with the premise for "The Da Vinci Code." She also alleged that Brown hid scores of future projects worth "millions" from her, including a television series as well as a children’s book.

CLICK HERE TO SIGN UP FOR THE ENTERTAINMENT NEWSLETTER

Blythe had accused the author of having multiple affairs during their marriage.

Blythe had accused the author of having multiple affairs during their marriage. (Photo by Rolf Vennenbernd/picture alliance via Getty Images)

At the time of the lawsuit, Dan Brown said he was "stunned" by the allegations and called the complaint "written without regard for the truth." He said he never misled his ex-wife on their finances during their divorce and that she ended up with half their holdings after they split up.

The couple divorced in 2019 after 21 years of marriage.

Brown, a New Hampshire native, has had a string of bestsellers but is best known for "The Da Vinci Code," a puzzle-filled thriller that introduced readers to the notion that Jesus Christ and Mary Magdalene were married with children. The plot outraged church officials and scholars.

CLICK HERE TO GET THE FOX NEWS APP

The former couple agreed to voluntarily dismiss the lawsuit.

The former couple agreed to voluntarily dismiss the lawsuit. (Photo by Michael Stephens - PA Images/PA Images via Getty Images)

During a 2006 trial against the publisher of the "The Da Vinci Code," the court heard how Blythe Brown was an essential contributor to the thriller. Two authors unsuccessfully sued, claiming that Brown "appropriated the architecture" of their book in a high-profile London court case.