Object o = expression.elementAt(i);
if (o instanceof PtgMemFunc){
PtgMemFunc pmf = (PtgMemFunc)o;
Stack s = pmf.getSubExpression();
for (int x=0;x<s.size();x++) {
Object ox = s.elementAt(x);
if (ox instanceof PtgArea3d) {
PtgArea3d p3d = (PtgArea3d)ox;
p3d.setReferencedSheet(newSheet);
}// do we have other types we need to handle here? (within memfunc)
}