The tweets set off alarms in San Juan, the Puerto Rican capital, where Ricardo A. Rosselló, the governor, anxiously called John F. Kelly, the White House chief of staff, to seek an explanation. Mr. Kelly reassured him that no federal resources were being withdrawn anytime soon and then made an unannounced visit to the White House briefing room to repeat the message for the news media.

“Our country will stand with those American citizens in Puerto Rico until the job is done,” Mr. Kelly said. The president, he asserted, merely meant that eventually the federal government would complete its mission. “The whole point is to start to work yourself out of a job,” he said.

Shortly after, his deputy, Kirstjen Nielsen, in accepting Mr. Trump’s nomination to succeed Mr. Kelly as secretary of homeland security, added her own soothing words. “I also know that this rebuilding will take years, and I want to echo what the president has said many times: We will remain fully engaged in the long recovery effort ahead of us,” she said in the East Room.

But Mr. Trump did not say that on Thursday, even given the opportunity to clarify at the ceremony formally announcing Ms. Nielsen’s nomination. Instead, his message provoked another wave of criticism from the island and its supporters. They expressed astonishment that Mr. Trump would assail the very people he was supposed to be assisting, in contrast to the tone he has taken with Florida and Texas, where National Guard troops and Federal Emergency Management Agency workers are also still helping with hurricane recovery.

Carmen Yulín Cruz, the mayor of San Juan who has been critical of Mr. Trump’s response and rebuked by him in return, condemned his latest message as adding “insult to injury” and called on international organizations to step in to prevent “the genocide that will result from” Mr. Trump’s inaction.