>Hi Beth.
>
>>Can someone tell me why This.NewObject() would return a .T. even if the object being created by NewObject did not instatiate?
>
>The VFP Help file doesn't indicate any return value for the NewObject method, so I'm guessing that it always returns .T. I agree that it would be nice if it returned .F. if the instantiation didn't work, but in the meantime, you can use code like the following instead:
This.NewObject('NewMember', ...)
>if type('This.NewMember.Name') = 'C'
>* object was created
>endif
Doug
Thanks Doug.
It is curious to me that the function NEWOBJECT() does seem to return .F. if instatiation doesn't work but that the method This.NewObject() always seems to return .T.
Anyway, thanks for reassuring me that I'm not going crazy (at least in this particular case <g>).
Beth Wetherbee, MCSD
VBCPS