sweep command

hello

i am facing a problem in sweep command.

i have a sketch and a curve.

i made a macro and when i run the macro the error occurs.

run time error '450':

wrong number of arguments or invalid property assignment.

any solution please give some sample code.

SolidworksApi macros