>I've created a custom class visually that has a method that takes 4 parameters; two are objects and two are variables.
>
>I dropped the class on a form and invoke its method from a command button, passing the four parameters.
>
>The objects come back properly modified by the method, but the variables come back in their initialized state. I've displayed the variables on the last line of code in the method and they do have the correct values there. I also noticed that in the form, the method code box for the object has an LPARAMETER line with my parameters. My first line of code in the object method is a PARAMETER statement. Why is that? How can I get the values of the variables back to the form?
>
>Thanks
>Jay
I think from what you are saying that you need to pass the two variables by reference not value.
so instead of having
ThisForm.oMyObj.MyMethod(o1, o2, v1, v2)
have
ThisForm.oMyObj.MyMethod(o1, o2, @v1, @v2)