Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Need help with Classes
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00404624
Message ID:
00404627
Vues:
9
>1 - I have a class and would like to copy it without sub-classing it. The 'SAVE AS' is disabled on the file menu. Any suggestions?

You can use the project manager to copy classes from one ilbrary to another and to rename and delete a class, using this, you should be able to do what you want.

>2 - How does one convert a class from a PRG format or from the command wndow to a visual class?

Off, Nigel's page:


If you have some classes written in procedure (prg) files and want to convert them to VCX classes, follow these instructions.

Create a form or open an existing form you want to attach the class to.

In the command window, SET PROCEDURE TO your .prg file containing the class definition.

Type: lnResult=ASELOBJ(laObjects,1)

Type: laObjects[1].ADDOBJECT("classname","classname")

Replace "classname" with your own class defined in code.

You now have an object on your form. Select the object and go to File|Save As Class and save this in whatever class library you want!
You will need to include the prg file in your project.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform