Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ATLINE() bug and workaround?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00138760
Message ID:
00138941
Vues:
18
Hi Rick,

>Uhm, how do you go from char location to line location and back? I don't
>think you can.

Why do you need this? What I meant was something like
  lnLine = ATLINE("World",lcMemo)
  lcLine = MLINE(lcMemo,lnLine)
  IF RAT("World",lcLine) = LEN(lcLine)-Len("World")+1
     * it's the last character
  ENDIF
>Once you find the line and need to go on you can't use ATLINE
>anymore either cause it doesn't have a nOccurance option like AT.

Why? After you used MLINE(), the _MLINE variable is set to the next line, so
SubStr(lcMemo,_MLINE)
gives you the rest of the string. You just continue to search until you can't find anything else.

>I was working on PRG files (as text) that were like 50k or so and it took
>3 minutes to parse out just the function names. MLINE() and ATLINE() both
>are very, very slow on large text strings it appears.

That definitely sounds like you don't use the _MLINE variable with MLINE(). Actually these operation can be quite fast.

Christof
--
Christof
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform