alberto7783
Technical User
Hello !!!<br>I'm just trying to make a project that with a Module where I define the Type Complex an a Public Function to add complex numbers as:<br><br>Type Complex<br>real as double<br>imaginary as double<br>End Type<br><br>-----------------<br>Public Function AddComplex(a as Complex, b as Complex) as Complex<br><br>Dim aux as Complex<br><br>aux.real=a.real+b.real<br>aux.imaginary=a.imagirary + b.imaginary<br><br>AddComplex=aux<br><br>End Function<br><br>-------------<br>But when I execute this function in a Form with a Command button trying to add two Complex numbers there is an error pointing to the function.<br><br><br>THE QUESTION IS:<br>Does anybody know if it's possible use type objects as arguments of functions?<br><br><br>