Used getVar instead of  to find contact and membership ids.