Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Populating List Box from Table
Message
 
 
À
24/10/2001 08:30:08
Ashish Patel
Hindustan Petroleum
Mumbai, Inde
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00572474
Message ID:
00572538
Vues:
21
Hi!

Better read articles in the programmer's guide. I can describe this only briefly:

1. In the project manager open the Classes tab. Press New button. Enter Class name (MyGridClass, for example). Select from "Based On" combobox Grid. In the "Store In" field type the name of the class library file that will contain classes. Ok. Now you see just a grid for editing. Add new method (as for the form). Find that method in the properties sheet. Open and put code into it. Close code window. Save Grid class and close class editor. Open your form. Drag and drop your new grid class from the project manager into the form. You now have a grid on form based on your custom class. Each time you will change the class, these changes will also apply to ALL forms that use this grid class. When application is running, when no code on form for such object and there is a code in the class for it, code in the class will run. You can forward running of code into the class from the code on form using Dodefault() or "::" operator. You can base class on your custom class making this way object classes hierarchy.

It is also recommended to read some OOP book to understand more the purpose of the classes and terminology related to them.

HTH.

>Hi
>
>As per your mail I was going thru FAQ#812.
>
>(You can make grid looks like a listbox using the tips from FAQ#8092)
>
>I am having only one doubt
>
>procedure SetupColumn && make it as a form or grid class method
>
>
>How to make this a class ?
>Can you pl. tell me step by step since I am new to classes.
>Do i have to paste the code in different .prg file or how ?
>
>I tried to create a New Method by that name and then pasted the code
>but I got error.
>
>Can You pl. throw some more light on it ?
>
>
>Thanks
>
>Ashish Patel
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.com
ICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs

It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform