bug fixed; added getValue functions