Hi there,
Yes that will work fine but there are a few things to think about.
1. Do not smoke near it because its "Flamable" it could easily set your computer alight if it comes it contact with a flame or smoke.
2. Compressed air can emit a bit of water, you could use a moisture trap or dehumidifying filters can be used to remove the moisture from the can but this is only optional really.
3. Be careful that if any liquid leaks from the can it doesn't land on your computer.
Apart from that it should be fine!
Hope this helps!