Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Create VS Define Classes
Message
From
16/03/1999 11:24:14
 
 
To
16/03/1999 10:53:23
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00196090
Message ID:
00198129
Views:
19
>Thank you guys, for all your help. It's coming together, slowly but surely. I guess my main frustration is being thrown into it without the proper learning. I have a computer background since graduating college in 1975, but even when beginning work in FPDOS 2.0 in 1991, I had the luxury of having the time to read thru the entire Commands & Functions book *and* the Developer/Programmer's Guide *before* really doing much of anything worthwhile. I had time on my hands (wasn't really employed at the time) to play with things. (I knew dBase, so it wasn't much of a stretch). However, with VFP, I've started with developing a system for a client without having had any practical experience with OOP ... my client knows this and was willing for me to do the project anyway (I also maintain a FPW 2.6 system for them, so they like me), but it was probably a mistake for me to take this on. It's coming along ok, but really slowly (if I had done it in FPW 2.6, it would've been done long ago!) and I'm
>sure as I learn more about the OOP mentality, I will probably be re-writing the system in order to do it right! Arrrggghhhh!!!
>
>Anyway, thanks for all your input, it *does* help me to start thinking along the right lines. I'll keep plugging!!!
>
>Bonnie
>

Bonnie,

We had Mac Rubel speak at our Fox Users Group one night about OOP programming when VFP was still very new. He said pretty much that no matter how much design effort you put into your classes, that you would probably need to rewrite things about eight (8 !!!!) times before you got things exactly the way you wanted them. At first I thought, "He's crazy! I'll never need to re-do things that many times to get it where I want it to be!" Turns out, Mac's almost dead-on with that statement. We're about at our 6th revision of classes and concepts, and it's much closer, but not quite there yet. So it seems eight is about correct. Now it's not a total re-write, but there have been a few corners we painted ourselves into, and it usually only involves a metamorphosis to the next level, but it's nowhere near what we started out with, (you know, the "perfect" design!).

So don't despair, it really does get better with each "refinement".

PS:
We used to keep all our code in the calling .PRG for a screen, too! It really does seem like the code is now scattered all over the place. But that's where the true power and flexibility of OOP comes in!

Fred

>
>>Bonnie,
>>
>>>> It seems that my code ends up being all over the place and it's hard to find things. <<
>>
>>If I can stray away from the technical for a moment, let me just say, "Hang in there." I developed a complete class library in VFP 3, which seemed so great in conception, but seeemed like nothing but a collection of mistakes when I was finished. But I used it anyway and resolved not to go rewriting until I'd soaked up more wisdom. Now, two years later, I've crafted for myself a complete framework based on ideas I'm comfortable with, and not a few of them due to stumbling down blind alleys at first.
>>
>>>> It's obvious to me that I'm doing something wrong, cuz it's supposed to be easier, not harder, but I think I'm
>> missing something important. <<
>>
>>Well, again, I think most on this forum (who are honest <s>) will admit that OOP thinking has some alien aspects to it. If you keep plugging, the light bulb does go on.
>>
>>>> .... Now, with OOP, we're back to putting stuff in a gazillion different places, and this is why I
>> think I may be misunderstanding some basic concepts and I may not be doing things correctly. It seems like a step backward to me. <<
>>
>>My experience exactly, but it does not have to be. You can subclass and still call out to other sources, which is what I do for WHEN and VALID. IOW, all of my controls call "oDD.When(this,thisform)" and "oDD.Valid(this,thisform)". This keeps all of my framework WHEN and VALID logic in one place, while having it accessed from all controls.
>>
>>It's really cool if you keep at it. Hope this helps.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform