A chastened Donald Trump marked the final batch of primary contests Tuesday by attempting to shift to the general election in style and substance, following weeks of controversy and missteps that knocked his campaign off course.

“Tonight we close one chapter in history and begin another,” the presumptive GOP nominee said.

Speaking from his golf club in Westchester, N.Y., with the aid of teleprompters, a rare move for the celebrity businessman who lives off-script, Trump said it would be an “honor to lead the Republican Party to victory this fall.”

“I understand the responsibility of carrying the mantle, and I will never ever let you down,” he continued. “I will make you proud of our party and our movement.”

Although he delivered his remarks to a room of supporters, Trump was sending a message to Republican leaders and elected officials, who have been in a panic over Trump’s recent demeanor — particularly his attacks on Judge Gonzalo Curiel, whose “Mexican heritage” Trump said should disqualify him from hearing a fraud case against Trump University. Republicans have panned the attack as unproductive at best and racist at worst.

“It’s time to quit attacking various people you competed with or various minority groups in the country and get on message," Senate Majority Leader Mitch McConnell urged Trump in remarks to reporters Tuesday. "He has an opportunity to do that. This election is eminently winnable. The American people at their core do not want four more years like the last eight. I hope that's what he will do. We are all anxious to hear what he may say next."

Trump clearly moderated his message Tuesday. He did not invoke the wall he would seek to build on the U.S. border with Mexico, nor did he acknowledge the swirling controversy over his comments regarding Judge Curiel.

This leashed version of the normally bombastic candidate was met with quick approval from Republican National Committee Chairman Reince Priebus, who for weeks has sought to soothe GOP concerns about Trump’s fitness for the presidency.

“Great victory speech by (Trump) tonight,” Priebus tweeted. “Exactly the right approach and perfectly delivered.”

But frustration had built for weeks among Republicans, who have puzzled over Trump’s lack of campaign growth, dubious commitment to fundraising or message discipline, and quixotic and time-consuming jaunts to California and other states that will have no bearing over the general election outcome.

Meanwhile, the past month has been rife with controversies that have dented Trump, including a Washington Post report that showed he had not disbursed millions of dollars he had raised for veterans groups, in addition to a $1 million personal donation. Trump hurriedly wrote the checks when the Post approached him with questions, and afterward excoriated the media in a fiery news conference at Trump Tower.

As he has sought to drown out the steady drumbeat of unfavorable press, Trump has inconsistently trained his fire on his true rival, Hillary Clinton, who clinched the Democratic nomination Monday.

“We’re going after Hillary Clinton,” Trump said in his remarks last month after winning the Indiana primary and effectively wrapping up the Republican nomination.

But the past month has unfolded differently than Trump previewed that night, or than GOP leaders had hoped it would. Some Republicans now worry he has squandered his head start against Clinton and any strategic advantage that might have afforded him.

The exasperation seemed to reach a boiling point this week as Republicans rushed to distance themselves from Trump and reprimand him. “He’s got this defining period over the next two or three weeks where he could pivot, can pivot, hopefully will pivot to a place where he becomes a true general election candidate,” Sen. Bob Corker said Tuesday.

Clinton, by contrast, has not wasted time in taking the fight to Trump. She blasted her would-be rival last week in a speech billed as a foreign policy address, warning of the consequences of Trump in the White House.

"Donald Trump's ideas are not just different, they are dangerously incoherent," Clinton said in San Diego. "They're not even really ideas, just a series of bizarre rants, personal feuds and outright lies."

In his remarks Tuesday, Trump promised a major speech next week targeting the Clintons. “The Clintons have turned the politics of personal enrichment into an art form for themselves,” he said.

And he underscored a central theme of his campaign: his outsider status relative to Clinton, who has served in office for decades.

“I’m not a politician fighting,” Trump assured his supporters, despite his more measured tone. “I’m me.”