Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to merge 2 arrays in 1 ???
Message
 
À
15/07/1997 12:31:51
Vinod Parwani
United Creations L.L.C.
Ad-Dulayl, Jordanie
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00040005
Message ID:
00040217
Vues:
23
> Acutally, I want length(s) of some fields in program, if it will be in one > array I can use 1 ascan command and find out.. without searching in > multiple arrays... Don't forget that ASCAN stops on the first hit. If you have the same fieldname in multiple tables, then you won't necessarily find the right field. In this case, I would use the following *Untested* code:
create cursor dbfstru (table c(8), field c(10), length n(3), decimal
n(2))
select 0
m.lcDBF = sys(2000,"*.DBF")
do while not empty(m.lcDBF)
  use (m.lcDBF) again alias ___Import
  m.lcDBF = left(m.lcDBF,rat(".",m.lcDBF)-1)
  m.lnFields = afields(laTemp)
  for m.lpCount = 1 to m.lnFields
    insert into dbfstru values ;
                (m.lcDBF, ;
                 laTemp(m.lpCount,1), ;
                 laTemp(m.lpCount,3), ;
                 laTemp(m.lpCount,4) )
  endfor
  m.lcDBF = sys(2000,"*.DBF",1)
enddo
if used("___IMPORT")
  use in ___Import
endif
Paul Russell
EMail: prussell@fox.nstn.ca
Phone: (902) 499-5043
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform