Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Dangling Datasessions
Message
De
23/02/2001 16:22:51
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
 
À
23/02/2001 08:45:57
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00478620
Message ID:
00479066
Vues:
33
>Hi Erik - thanks for your input!
>
>I do have quite a bit happening in the INIT. The form is for managing imports into my system from external data sources. The INIT runs an extended "create table" command to create a temp "import-to" table, it then creates a field list of the data to import and populates a listbox with the field headers. However if the user selects an invalid file to import, none of that other code runs. That's when I try to return .f. in the init.
>
>I don't know if it matters, but virtually all the above mentioned code, including checking for a valid data file, happens in other methods, which are called from the init. They return .t. or .f. depending on the success. If there is any .f. return, the init returns .f.
>
>Oddly, I've created an lOKtoContinue property of the form. Since I can't get the init to bail out successfully, I set this property in the init, then check it in the ACTIVATE event, and if its false, I release the form. The data session gets released with it. So I've got a work-around, but it's still nagging me because it's sloppy code.

I have a form of the kind, but since it has to pick between a few import files, it has to show up anyway.

In your case, why don't you try to do this checking in the .load, and return .f. from there - the DE shouldn't even show up.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform