I can't believe people are having problems addressing this issue. It was resolved in the movie itself!
Later, at the New Avengers facility, when Stark, Rogers, and Thor are talking about the Infinity Stones and about whoever's playing a game with them, the following conversation occurs:
Captain: So if we keep the hammer in an elevator...
Stark: It would still go up.
Captain: Elevator's not worthy!
Then they say that the laws of worthiness only apply to living things, and since the Vision was not a living being but an android, he could lift it.
Also, on a side note, the one and only criteria for lifting the hammer is worthiness, nothing else. All those who have wielded the hammer are exceptionally worthy beings (Captain America, Superman, Beta Ray Bill) and their worthiness is perfectly recognizable. Cap's amazing integrity and righteousness was the main reason why in the movie's opening "Lifting Mjolnir" scene he was able to shake the hammer a bit.
EDIT: Many people have a problem with me saying that Superman lifted Mjolnir because he does not belong to the Marvel universe. So here ya go. One of the most spectacular scenes in comic book history:
This happened in the JLA/Avengers crossover comic.
Captain: Elevator's not worthy!
This happened in the JLA/Avengers crossover comic.