Compiler is right. setLocked is not declared in your code, but you have codigosecreto and other variables declared.