>Is there are way you can execute a marco-substitution in c#, like you can in VFP?
>In VFP it's something like this:
>
>use sometable
>lcCmd = "BROWSE"
>&lcCmd
>
>
>Is there a way you can do something like it in c#?
>
>Thanks.
Sandy, just as a follow-up...I realize you were using the browse command just as an example. Having said that, actual needs for reflection (or something more elaborate) are going to be more involved than that.
Where you often see examples of reflection is when someone needs to investigate objects/properties at runtime. The .NET framework itself uses reflection under the hood (or at least at one time it did).
Before generics came around, I had an application that dealt with insurance policies. Based on the kind of policy renewal, there were a variable # of documents generated. So for that and other reasons, we used reflection. But when generics came around, we used it as an opportunity to tweak the design and use generics and interfaces. It's a big learning curve but it's worth it.