Lizards are a group in the clade Squamata. Dinosaurs are in the clade Archosauria. Both clades fall under the class Reptilia, so they are related distantly, but no, a dinosaur is not a lizard. Birds are extant dinosaurs, and they are also not lizards, but they are reptiles.