Find and replace macro

How can I write a find and replace macro to merge many items in few, as “USA, Mexico, Canada, Honduras” in “America”, “China, India, Vietnam” in “Asia” and so.
Before macro: USA, Mexico, Canada, Honduras
After macro: America, America, America, America

Thanks

It can be something like this:

Sub Geographer
Dim oDoc As Variant
Dim oSearchDescriptor As Variant
Dim oDictionary As Variant
Dim oReplace As Variant
Dim oStatusIndicator As Variant
Dim i As Long, j As Long 
	oDoc = ThisComponent
	oStatusIndicator = oDoc.getCurrentController().getStatusIndicator()
	oDictionary = Array( _
	Array("America",	"USA", "Mexico", "Canada", "Honduras"), _
	Array("Asia", 		"China", "India", "Vietnam"), _
	Array("Europe",		"Ukraine", "Italy", "France", "Germany"), _
	Array("Africa",		"Qatar", "Tunisia") )
	oSearchDescriptor = oDoc.createSearchDescriptor()
	oStatusIndicator.start("", UBound(oDictionary)+1)
	For i = LBound(oDictionary) To UBound(oDictionary)
		oReplace = oDictionary(i)
		oSearchDescriptor.setReplaceString(oReplace(0))
		oStatusIndicator.setText(oDictionary(i)(0))
  		oStatusIndicator.setValue(i+1)
		For j = 1 To UBound(oReplace)
			oSearchDescriptor.setSearchString(oReplace(j))
			oDoc.replaceAll(oSearchDescriptor)
		Next j
	Next i
	oStatusIndicator.end()
End Sub

Thank you very much. I will try.

It works perfectly!!! Very good. Thank you!!