Claire,
You should always state what version of ArcGIS you are using if you want us to help you as this dictates what can or cannot be done.
If you have ArcInfo then have a look at this tool Feature Vertices To Point in the Data Management toolbox. You could then add M and Z fields and populate using a simple calculate script extract the ZM values.
Duncan