Potassium Nitrate is used because both potassium and nitrate salts are soluble with a large number of other anions and cations. It means you dont have salts precipitating out of solution in your cell.
You could use any soluble salt so long as it doesnt precipitate when it comes into contact with the other ions.