Nafise Salehi it seems the atom type NPri which part of the coordinate file is not found in your topology file. This is the reason why you couldn't generate a tpr file. Read about more the generation of the topology file.
More details are needed to try to suggest something, are you running a protein-ligand tutorial? If this is the case, you are surely omitting the force field of the ligand.