I have resolved this issue.
Both
member.getProperty(“memberBooks”).Value = booksValue;
and
member.SetProperty("memberBooks", booksValue);
work
I was just passing wrong values.
In the contentXml they display as values but actually I need to update the property with the ids so if the data type is checkbox list and the values are like:
1 - book
2 - booko
3 - booki
then in the contentXml it displays as a list "book,booko,booki" but to update it programatically I had to pass: "1,2,3" to the property.
So it should be:
member.SetProperty("memberBooks", "1,2,3");
instead of:
member.SetProperty("memberBooks", "book,booko,booki");
I hope it helps others with the same problem.