DAVID FROST says:
I assume from your email address that you are in Scotland. Crows and other corvids may be shot under general licence and you can view these at www.basc.org.uk/content/pestandpredatorcontrol.
It is absolutely essential that you read the licence before you shoot to ensure you are complying with its terms and conditions.
Preventing damage to window seals is not covered by the licence.
However, if you can satisfy yourself that the birds are a threat to public health or safety or are likely to spread disease then you may shoot them.
If you are not the landowner you must obtain his consent before shooting.
You mention a .22 rifle but do not say if it is .22RF or an air rifle. If it is a .22RF you need to check the conditions on your Firearms Certificate to ensure they cover shooting avian pests.
If not you need to get the Firearms Certificate varied.
No permit of any description is needed to use a .22 air rifle but you may not shoot in such a way that the pellet goes beyond the boundary unless you have the neighbour’s prior consent.
In both cases you need to ensure that the use of a rifle will be safe.
For this reason it is often easier to use an air rifle rather than a .22RF.