Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
CLR and VFP
Message
 
À
31/08/2000 14:24:14
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Divers
Thread ID:
00409695
Message ID:
00412022
Vues:
22
>I saw a decent argument made for EVAL(), which I agree is a very nice feature. I don't know enough about the internal workings of macros and EVAL() to know how closely the two are tied, but I would kick and scream a lot louder if you asked me to give up EVAL.

I use EVAL() whenever I can but EVAL() can't handle a few things like assignments (ie. the left side of an assigment) and things like full commands.

>
>>One more question. What do you think of the importance of the COMPILE command ?
>
>To be honest, I think it's a really cool feature, but I have yet to use it in production. I can see how it might be very important to the author of a programming tool (like WWWC) or any other application that might need to generate code on the fly.

I use it alot even in commercial business apps. For example, Help Builder uses it to compile HTML pages and runs them (although youy can also use CodeBlock for that). Web Builder compiles component code on the fly then runs it. Web Connection uses it for script pages and now Web Services to allow you to change the page and then recompile it at runtime automatically.

I agree though - it's a very cool feature that let's you do some amazing stuff (for example, write client side code, pass it over the Web for VFP to process and return the result - SOAP <s>). The client can actually create the code to run and then have the server dynamically run it.

But regular business applications probably don't need this. However, remember that tools that you use today may take advantage of this without you knowing. VFP itself does. All of the Intellisense stuff in VFP7 for example is all based on dynamnic execution of code stored in a DBF file.

As far as Eval() and Macros go - they're in the same vein. You don't have eval in other languages either although in a P-COde environmnet like VB and CLR it should be possible to do. I really can't imaging writing framework level code without eval - which means you'd end up hardcoding a lot of things (like field names and properties). Think about a tool like wwXML - without eval you couldn't do what it does...
+++ Rick ---

West Wind Technologies
Maui, Hawaii

west-wind.com/
West Wind Message Board
Rick's Web Log
Markdown Monster
---
Making waves on the Web

Where do you want to surf today?
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform