After a setback for the Republican agenda Tuesday, President Donald Trump sounded an optimistic tone on reaching an agreement on an Obamacare replacement.

At a White House meeting with GOP senators, Trump shrugged off the Senate delaying a vote on its health-care bill, saying "we're getting very close" to striking a deal despite remaining disagreements. But he sent mixed signals on the Senate's ability to reach an agreement and "solve" Obamacare, which he said was "melting down."

"This will be great if we get it done. And if we don't get it done, it's just going to be something that we're not going to like, and that's OK, and I understand that very well. But I think we have to do something very, very important for the public," Trump said, while flanked by Sens. Susan Collins of Maine and Lisa Murkowski of Alaska, two GOP swing votes on health care.

Senate Republicans are delaying a vote on their Obamacare replacement bill until after July 4, Senate Majority Leader Mitch McConnell said Tuesday, as the party faces opposition from enough GOP members to block the measure. McConnell said GOP leaders are "still working toward getting at least 50 people in a comfortable place."

Republicans face difficulties in winning over skeptical senators, as tweaks to appease conservatives could alienate moderates, or vice versa. The hurdles threaten to delay a key plank of the sweeping agenda Republicans hoped to pass when Trump won the White House and the GOP held onto both chambers of Congress.

After the White House meeting, McConnell told reporters, "either Republicans will agree and change the status quo, or the markets will continue to collapse and we'll have to sit down with Senator Schumer." The Senate majority leader said he suspects the Republicans would not be able to get the reforms they want if they have to negotiate with the Democrats.

Trump tweeted Tuesday evening that the Republicans are working hard without support from the other side of the aisle.

On the conservative side, Sens. Rand Paul of Kentucky and Ron Johnson of Wisconsin also said they would not back a motion to proceed this week for the bill as written. Sen. Mike Lee of Utah also said he would oppose the procedural move barring tweaks to the bill, according to The Associated Press.

Those senators and Ted Cruz of Texas were the first to publicly announce opposition to the current bill. They argue that the plan does not go far enough to repeal Obamacare.

After the vote was delayed, three Republican senators — Jerry Moran of Kansas, Rob Portman of Ohio and Shelley Moore Capito of West Virginia — announced opposition to the current bill. Portman and Capito were considered swing votes because their states have expanded Medicaid and are hotbeds in the U.S. opioid crisis.

The GOP could still win skeptical senators over with amendments. House Republicans did the same to gather more votes before the chamber narrowly passed its own Obamacare replacement last month. The House GOP had to pull a version of its bill from the floor in March.

After McConnell announced the delay, Senate Minority Leader Chuck Schumer, D-N.Y., said, "The fight is not over" and Democrats do not yet feel "any sense of accomplishment." He argued that the bill is "fundamentally flawed" regardless of the tweaks Republicans make.

Schumer said he would work with Republicans on fixing Obamacare's problems if it does not repeal parts of the law, roll back Medicaid expansion and cut taxes for wealthy Americans. He said he wanted a less secretive process, as well.

Asked earlier whether he expected to work with Democrats, McConnell said, "They're not interested in participating in this."