Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Scanning an array for an object
Message
De
15/09/1999 10:01:56
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00264901
Message ID:
00264907
Vues:
14
>Hi,
>
>I have a 2 dimensional array that holds information about current forms. One of the columns holds an object reference to the form.
>
>I am trying to do an ascan to search for an object reference and get an "Operator/Operand type mismatch" error.
>
>The code is like this - I call a procedure oPos.releaseform(thisform)
>
>and in oPos.releaseform i have:
>
>lparameters toform
>
>ascan(this.yaforms,toform)
>
>Thanks for any help,
>Paul


lparameters toForm
lcTempName = toForm.Name
toForm.Name = "xxxx"
for ix = 1 to alen(this.yaforms,1)
  if compobj(toForm, yaforms[ix,1])
    toForm.NAme = lcTempName  && Restore name
    return ix 
  endif
endfor
toForm.NAme = lcTempName  && Restore name
return 0 && Nomatch
In VFP6 you can directly use "=" operator instead of compobj.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform