Ho risolto, ho adatatto un codice trovato in internet...
GRAZIE cmq di tutto