Electrical dimmer switches are used to control the flow of current to the light fixture. This in turn increases or decreases the light level in the room and changes its ambient mood. Dimmers fit in standard size wall switch boxes and are connected with normal 12 gauge or 14 gauge electrical wires that hook up to a regular switch. If the dimmer does not work, it's best as always to first check the easiest possible issues before moving on and deciding whether to replace the dimmer unit itself.
Locate the home's breaker box and check if the circuit breaker that serves the dimmer's light circuit is switched on. If it is off, turn the breaker on and turn on the dimmer. If the dimmer fails to work, turn off the breaker. Check the bulb(s) in the light fixture to see if the filament inside has broken: There usually will be a dark patch on the inside of the bulb if broken, or if lightly shaken the broken filament can be heard moving around inside the bulb.
Replace the broken bulb(s), turn on the breaker and check the dimmer to see if it works. If it doesn't work, turn off the breaker. Unscrew and remove the dimmer's faceplate. Also remove the two screws holding the dimmer to the switch box. Carefully pull out the dimmer and wires from the box. Check all wire connections to make sure none have come loose: The two black wires will either be directly connected to the dimmer's terminals and held in place with screws, or the two black wires from the box will connect to the two black wires coming from the terminal, using wire nuts. Also check the two white wires in the back of the box that are connected together with a wire nut, as well as the two green ground wires in the back of the box (either attached to a terminal screw in the back of the box, or connected together with a wire nut).
Remove all drywall dust from the switch box and/or back of the dimmer switch. Push the dimmer and wires into the box, insert the screws and reinstall the face plate. Turn on the breaker, and also turn on the dimmer. If the dimmer still doesn't work, turn off the breaker. Remove the dimmer's face plate and screws holding the dimmer unit inside the box. Pull out the dimmer unit from the box.
Remove the two black wires from the electrical box that are attached to the dimmer unit. Cut a section of black wire from a 12/2 or 14/2 electrical cable (roughly six inches long), strip 1/2-inch of plastic coating from each end, and use a wire nut to connect each end of this section of wire to the two ends of the black wires that were connected to the dimmer. Turn on the breaker. If the lights on the light fixture come on, the dimmer itself is causing the problem and needs to be replaced.
Make doubly sure that the breaker is off when working on the dimmer.