Visa rules vary by country. It is therefore extremely important to check with the Spanish Consulate in the country in which you currently reside.
The process of applying for a visa starts long before your arrival in Spain. You can request your student visa at the Spanish Consulate in your home country after receiving an acceptance letter from UIC Barcelona (you will need to present this letter at the Spanish Consulate).
We recommend you submit the visa application two or three months before travelling.
If you are applying from a country in which Spanish is not the main language, you will need to translate all required documents into Spanish through an official channel. This means that you will need to contact a Sworn Spanish Translator. Please contact your local Spanish Consulate for a list of official translators.
List of consulates and embassies:
http://www.exteriores.gob.es/Portal/en/ServiciosAlCiudadano/Paginas/EmbajadasConsulados.aspx