The New York attorney general has served the Trump Foundation with a cease and desist order that requires it to stop fundraising in New York, alleging it is not properly registered in the state.

'The failure immediately to discontinue solicitation and to file information and reports ... with the Charities Bureau shall be deemed to be a continuing fraud upon the people of the state of New York,' according to a letter dated September 30 that the attorney general's office posted online.

SCROLL DOWN FOR VIDEO

Stop: Donald Trump was campaigning in Virginia as New York's attorney general issued the cease and desist against his charity

He's with her: Eric Scheiderman (right) is a Democrat who has appeared in public with Hillary Clinton, whose campaign has been highlighting the Trump Foundation

Eric Schneiderman, a Democrat, published the letter on his website, and in a statement accused the Trump Foundation of breaking New York law by having operated without a registration required in the state.

The move will highlight the role of the Trump Foundation amid scrutiny over its activities.

It is likely to be seen by the Trump campaign as politically-motivated and timed to capitalize on struggling poll ratings in the wake of last week's presidential debate with Hillary Clinton.

The Clinton campaign mentioned reports about the Trump Foundation not having the correct legal certification in an article on its website published hours before the attorney-general's announcement.

Schneiderman's warning is based on what he says is a failure by the Trump Foundation to file a registration with state authorities which allows charities to operate and fund-raise in the state.

The Trump campaign says the foundation intends to cooperate with the investigation.

The letter claims the foundation 'is in violation of section 172 of Article 7-A New York's Executive Law, which requires charitable organizations that solicit contributions in New York State to register with the Charities Bureau and to provide annual financial reports and annual audited financial statements'.

Schneiderman was already pursuing litigation against Trump over Trump University, a for-profit institution that was to instruct students on how to master real estate deals.

The New York attorney general accused Trump of 'mis[leading] consumers into paying for a series of expensive courses that did not deliver on their promises,' according to ABC News.

The inquiry into the Trump Foundation was connected with Trump University as a source in the attorney general's office told ABC that Schneiderman was looking into a $25,000 donation made by the Trump Foundation in 2013 to a group supporting Florida Attorney General Pam Bondi, who then declined to join a lawsuit against the billionaire over the now-defunct university.

He's with her too: Eric Schneiderman was photographed with Clinton's closest aide, Huma Abedin. Her husband is now being investigated by the FBI and New York Police Department's Special Victims Unit after DailyMail.com revealed he sexted a 15-year-old girl

Prosecutor: Eric Schneiderman, a Democrat, is the New York attorney-general responsible for the warning letter to the Trump Foundation

Trump denied that the donation was inappropriate, but had paid a $2,500 penalty to the Internal Revenue Service because charities aren't supposed to give to political groups.

The Trump Foundation said in July that the contribution was 'mistakenly made from the foundation.'

'Once Mr. Trump learned of the mistake from the news media, he publicly acknowledged the mistake and promptly took corrective action,' said a letter to the AG's office from the Trump Foundation.