Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
El objeto ya existe!!!
Message
De
27/06/2002 14:28:42
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
00672997
Message ID:
00673017
Vues:
23
If I understand you correctly (my Spanish is weak these days), To remove the reference to the object, see:

Re: Removing a _SCREEN hook Thread #643491 Message #643638

However, why do you need to free the object if you use it more than once? Why not set it as a property of _screen in your main program and always have it available instead of trying to add it everytime? You can modify its properties without adding it again, right?

Tracy

>Hola a todos...
>
>Tengo una pequeña clase que lo que me hace es agregarme
>un objeto label(con efecto de sombra) en la pantalla
>principal de VFP...
>
>y quiero llamar dicho programita en repetidas ocaciones
>pero luego a la segunda ves de ejecutarlo me dice :
>
> "Ya existe un objeto miembro con este nombre"
>
>esto haciendo referencia al siguiente codigo:
>_screen.AddObject('lblAreaShadow','LABEL')
>_screen.AddObject('lblArea','LABEL')
>
>
>Todo el codigo lo e puesto aqui:
>
> cArea = 'MiAreademiCompañia'
> nFontSize = 25
> nPosTop = 200
> nPosLeft = 125
> _screen.AddObject('lblAreaShadow','LABEL')
> _screen.AddObject('lblArea','LABEL')
> with _screen.lblAreaShadow
> .Visible = .T.
> .Top = (nPostop)
> .Left = (nPosLeft)
> .caption = (cArea)
> .fontsize = (nFontSize)
> .autosize = .t.
> .forecolor = 12632256
> .backstyle = 0
> endwith
> with _screen.lblArea
> .Visible = .T.
> .Top = (nPostop)+6
> .Left = (nPosLeft)+3
> .caption = (cArea)
> .fontsize = (nFontSize)
> .autosize = .t.
> .backstyle = 0
> endwith
> return
>
>como puedo "liberar" esta definicion cada
>ves que deseo usarlo sin emplear "CLEAR ALL"
>
>gRACIAS!!!!!!
.·*´¨)
.·`TCH
(..·*

010000110101001101101000011000010111001001110000010011110111001001000010011101010111001101110100
"When the debate is lost, slander becomes the tool of the loser." - Socrates
Vita contingit, Vive cum eo. (Life Happens, Live With it.)
"Life is not measured by the number of breaths we take, but by the moments that take our breath away." -- author unknown
"De omnibus dubitandum"
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform