Donald Trump said in Mexico Wednesday that he had a "great substantive, constructive exchange of ideas" with President Enrique Peña Nieto and if he is elected the two hope to work together on five objectives — including renegotiating NAFTA and recognizing "the right of either country to build a physical barrier or wall on any of its borders."

"Having a secure border is a sovereign right, and mutually beneficial," the Republican nominee said after a closed-door session with the Mexican president. "We recognize and respect the right of either country to build a physical barrier or wall on any of its borders to stop the illegal movement of people, drugs, and weapons.

"Cooperation toward achieving the shared objective, and it will be shared, because the safety for all citizens is paramount to the United States and Mexico," Trump said.

He later told reporters that neither he nor President Peña Nieto discussed who would pay for the wall. "We did discuss the wall. We didn't discuss payment."

But Peña Nieto said afterward on Twitter: "At the beginning of the conversation with Donald Trump, I made it clear that Mexico will not pay for the wall."

Al inicio de la conversación con Donald Trump dejé claro que México no pagará por el muro. — Enrique Peña Nieto (@EPN) August 31, 2016

Jason Miller, a Trump campaign spokesman, said that Wednesday's meeting was "the first part of the discussion and a relationship builder between Mr. Trump and President Peña Nieto.

"It was not a negotiation, and that would have been inappropriate.

"It is unsurprising that they hold two different views on this issue, and we look forward to continuing the conversation," Miller said.

Trump's other objectives included ending illegal immigration, ending drug cartels, improving the North American Free-Trade Agreement and keeping manufacturing jobs in the Northern Hemisphere.

"A strong, prosperous and vibrant Mexico is in the best interest of the United States," Trump said. "America together.

"Both of our countries will work together for mutual good and most importantly for the mutual good of our people."

Trump said late Tuesday that he was accepting Peña Nieto's invitation from last week to meet with him in Mexico City. The session came before his critical speech on immigration reform later Wednesday in Arizona.

Peña Nieto also invited Democrat Hillary Clinton for a meeting in Mexico City. A Clinton campaign spokesman said that the two would talk again at "the appropriate time."

But in a speech to the American Legion in Cincinnati, the former secretary of state slammed Trump's move as "trying to make up for a year of insults and insinuations by dropping in on our neighbors for a few hours and then flying home again.

"That is not how it works," Clinton said.

Trump's visit came after of week of attacks by conservatives that he was softening his position on immigration — a charge which he has denied, ruling out legalization and amnesty for the more than 11 million aliens living in the United States.

In remarks following Peña Nieto's after the meeting, Trump said that "I was straightforward in presenting my views about the impact of current trade and immigration policies on the United States.

"We're united by our support for democracy," he added. "A great love for our people, and the contributions of millions of Mexican Americans to the United States.

"I happen to have a tremendous feeling for Mexican-Americans, not only in terms of friendships, but in terms of the tremendous numbers that I employ in the United States.

"They are amazing people. I'm proud to say how many people I employ."

He praised "first- second- and third-generation Mexicans" in the country as "just beyond reproach. Spectacular, hard-working people."

Trump slammed the drug cartels and human smugglers who are bringing illegals, weapons and drugs into the United States.

“When cartels commit acts of violence, nobody wins," he said.

Regarding the trade agreement, Trump said that he "shared my strong view that NAFTA has been a far-greater benefit to Mexico than it has been to the United States.

"It must be improved upon to ensure that workers — and it's so important, that both countries benefit from fair and reciprocal trade.

"We must take tax to stem this tremendous outflow of jobs from our country. It is happening every day — and it is getting worse."

Peña Nieto said that he had "a very constructive conversation" with Trump and that "the objective of the meeting was to meet each other and talk about the bilateral issues."

The president also touted the benefits of the trade accord but added that "this doesn't mean that the North American Free-Trade Agreement may not be improved to benefit both parties.

"As partners, we need to work together to avoid all of the jobs leaving our region," Peña Nieto said.

He acknowledged problems with illegal immigration and said that U.S.-Mexico border "must transform itself as an asset for our region."

Peña Nieto noted that increased vigilance by the Obama administration has created "great success in the last few years," but that "we must accelerate this effort so that the Mexican and United States border is more effective."

