Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFP6 version of PreVFP historic code
Message
De
09/07/2004 00:56:23
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
00922398
Message ID:
00922405
Vues:
15
This message has been marked as a message which has helped to the initial question of the thread.
Well, I think the modern way to do it would be to put the user interface into a form. A separate form for such a small thing may seem exaggerated, but it does make the code more readable. If you don't want to have a separate form for this specific task, you might also define a form in code (through a class) - and get all the potential advantages of user interface, OOP, etc.

>Hi all
>
>I have just created the following code to get a selection of the data folder form the user as below. though it is working I just wanted to know if there was a more sophisticated way to do it.
>
>
WAIT CLEAR
>CLEAR TYPEAHEAD
>
>DEFINE POPUP DF MESSAGE "Select Data Folder" ;
>	PROMPT FIELD cName + " " + cExtra + STR(iID, 10) SCROLL
>	
>DEFINE WINDOW DF AT 6, 6 SIZE 10, 74 NONE NOCLOSE NOFLOAT NOGROW NOZOOM
>
>ACTIVATE WINDOW DF
>
>lcPrompt = cName + " " + cExtra + STR(iID, 10)
>
>@ 0, 0 GET lcPrompt FUNCTION "&T" POPUP DF SIZE 9, 64
>
>READ MODAL
>
>RELEASE WINDOW DF
>RELEASE POPUP DF
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform