I've seen some code like this
CComPtr<SketchCircle> pSketchCircle; pSketch->SketchCircles->AddByCenterRadius(pCenter,kDiam/2.0,&pSketchCircle);
But if I don't care about getting the actual object created can I pass NULL instead of &pSketchCircle?
Solved! Go to Solution.
Solved by xiaodong_liang. Go to Solution.
Hi,
I do not think so. But if you do not need the circle object, you could use the other function MethodXXX.
Actually I've just looked at the intellisense function prototype, and the last parameter is a default parameter and the default parameter is 0.
So yes, if you don't pass in a pointer to a circle then the last parameter is NULL by default.
Hi,
yes, you are correct. The param in this case can be NULL. I confused with others which require the param to be initialized.