While plants do release some matter, they do not have a complex excretory system that eliminates waste in the same way that animals like dogs and humans have. Oxygen gets secreted from most plants, and things like excess water and saps can also be secreted from plants, but these are not processed through an elaborate digestive and excretory system.
Though plants do typically release oxygen as a byproduct of photosynthesis, this is not considered excretion in the strictest sense of the word. Photosynthesis is the closest plants come to digestion, but because the process involves a conversion of light energy to sugars and other fuel rather than the consumption of and processing of a food item, the oxygen that gets produced as a result isn't considered to be excrement.
Similarly, though some trees and plants release saps, resins, latexes and syrups, these are considered to be extruded rather than excreted. This is because these secretions are extruded from the interior of the plant due to interior pressures. This can be seen as roughly analogous to blood rather than excrement because it is not an elimination of processed waste.
Though plants and trees do not have excretory systems like animals do, they do process and eliminate waste and toxins. These waste products are processed through roots, bark, tubers, fruits and stems.