The Shulhan Aruch (Orah Haim 527) writes that the cooked food used for the Erub Tabshilin must be a food item that is "Ra’ui Le’lafet Bo Et Ha’pat" – meaning, it is commonly eaten together with bread. Thus, it is customary nowadays to use a boiled egg, as people commonly eat egg with bread in a sandwich.
If a person does not have an egg, he should not use for the Erub something like rice, which is not normally eaten together with bread. Instead, he should use either a cooked piece of meat, a can of cooked tomatoes, or even a can of sardines, as these foods are commonly eaten together with bread.