However I get an error when the form starts up. "property width,height,top,left are not found. I added them! and they're public.
WHAT? You added public variables to hold these properties. NOT a good idea. The code I posted works as is - If you have a copy of 1001 Things You Wanted to Know About Visual FoxPro you can find a sample form and the form class in Chapter 11.