sample mxm code