generate code when we change language