That's what I thought, but I wanted to be sure.
Thanks
>Mu guess is that w/o NODEFAULT VFP tries to add control again after AddObject method finishes.
>
>>I want to place some code in the AddObject method of a container, so I have:
>>
>>
>>** METHOD AddObject
>>LPARAMETERS cName, cClass
>>
>>WITH This
>>
>> ** Add the control
>> DODEFAULT(cName, cClass)
>>
>> ** Position it show it
>> .Controls(1).Top = 1
>> .Controls(1).Left = 1
>> .Controls(1).Visible = .T.
>>
>> ** Set up the scroll container
>> ._Setup()
>>
>>ENDWITH
>>
>>
>>
>>Then I call:
>>
>>** Add the control to the container
>>ThisForm.MyContainer.AddObject("MyClass", "MyClass")
>>
>>
>>Which runs the code and crashes as it steps out. If I put a NODEFAULT after the _Setup(), it does
>>not crash and works fine.
>>
>>Not sure why this is. Can someone explain this?
>>
>>K
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people