Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Procedure or Class - What are the Benefits
Message
From
13/01/2003 08:59:56
Mike Yearwood
Toronto, Ontario, Canada
 
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00740837
Message ID:
00740945
Views:
38
Hi Alan

If you would leave the little procedure in its own .PRG file, there would be no need to SET PROCEDURE TO and it would be even faster (especially once you compile an EXE).

>Glenn,
>
>That is exactly what I needed to know.
>Thank you.
>
>>I mean that if the calling object has already done a "set procedure" to the procedure library which contains this procedure, there is no obvious benefit to contructing an object. In fact if no features of Object Oriented programming are needed, there is more overhead to creating and destroying an object.
>>
>>Glenn
>>
>>
>>>Glenn,
>>>
>>>By 'loaded' do you mean that there is a 'set procedure to' command or that any one of the procedures in the library has been accessed since the app has started?
>>>TIA.
>>>
>>>>If this procedure library is already loaded, ther is no advantage to creating a class, except if you have need to subclass.
>>>>
>>>>Glenn
>>>>
>>>>>I have a simple procedure which I have placed in a procedure library which, based upon a parameter passed, will delete all files from a directory with that filename and the various extensions (dbf, cdx, etc).
>>>>>
>>>>>Is there any benefit (speed of execution or otherwise) to creating a class and dropping it onto the forms that need to call this procedure?
>>>>>
>>>>>Thank you in advance.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform