When you say it doesnt work is it just dead?
Or does it carry on going but just no heat?
Ok for a no heat fault in a microwave it can be quite a few things.
It can be either an high voltage fuse (if fitted), magnatron, transformer, diode or capacitor.
So to find the fault you will need to test all of these. But microwaves are very dangerous to touch. As they can hold up to 4500v even when its unplugged.
So once you have the cover off you need to discharge the high voltage capacitor before touching anything in there.
But to be honest unless its just a fuse blown then anything else is worth the repair. As parts for microwaves are quite expensive compared to the price of a new appliance.
Like a magnatron is about the £80 the transfomer is £100+ so you will be able to replace the microwave cheaper then some parts in there.