Hi Martin.
Tryed Type('controlname')
Same result :(
.RemoveObject('Label2') is the first RemoveObject in the string of RemoveObject commands, looks like the first time it works properly and all the next RemoveObjects do not complete fully.
Still thinking...
Best wishes.
Kamil
>Hi Kamil,
>
> You must use TYPE().
>
> MartinJ
>
>>Hi.
>>VFP7.0, sp1.
>>The following code:
>>
>>With This
>>.RemoveObject('Label2')
>>.RemoveObject('Command3')
>>.RemoveObject('Command4')
>>* doing something irrelevent to Command3/4
>>?VarType(.Command3)+VarType(.Command4)+VarType(.Label2) - displays OOU
>>EndWith
>>
>>Changing to VarType(This.Command3) doesn't help
>>if i put VarType(.Command4.Tag)
>>"Unknown element" error message.
>>
>>...scratching the back of the head
>>yours truely
>>Kamil
A moment of silence is our cosmic reset button.