Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Ken Murphy
  Where is Ken Murphy?
 Springhill
 Canada
 Ken Murphy
 To: Benny Thomas
  Where is Benny Thomas?
 Jeddah
 Saudi Arabia
 Benny Thomas
 Tags
Subject: RE: _Screen.Property
Thread ID: 143128 Message ID: 143232 # Views: 1 # Ratings: 0
Version: Visual FoxPro 9 Category: Databases, Tables and SQL Server
Date: Sunday, August 26, 2007 2:26:07 PM         
   


> Dear Marcia,
>
> Nice thing. But like Syed, I also am not clear how and where to use this to get the settings. These settings can also be done though a normal code at the beginning of your main program. So what are the advantages (sure there are, otherwise you would not take the trouble) on going through a custom class? Would be grateful for your valuable time to give a reply.
>
> Benny
>
>
Benny,

The biggest advantage is that you create it once and you never have to create this code again. Lets say you created this code in your Main.prg. The next time you create an app, you have to do it all over again. (Yes, you could simply copy and paste, but when ever you find yourself copying and pasting, it is time to look at creating a class.) Once the class is created, you can then take advantage of inheritance. Let's say that for the second app, you now need to add some new functionality, for example, you want to add a new property called nConnHndl and you want a new method to connect to your database. You could sub-class this and then add your nConnHndl and Connect() to that subclass. Recommend that you take a look at my FAQ "subclassing basics" here: https://www.foxite.com/faq/default.aspx?id=49

Ken
You shall know the truth - and the truth shall set you free. (John 8:33)

ENTIRE THREAD

_Screen.Property Posted by Ahsan Rana @ 8/25/2007 5:58:06 AM
RE: _Screen.Property Posted by Bernard Bout @ 8/25/2007 7:14:52 AM
RE: _Screen.Property Posted by Tariq mehmood @ 8/25/2007 12:17:41 PM
RE: _Screen.Property Posted by Cetin Basoz @ 8/25/2007 12:47:48 PM
RE: _Screen.Property Posted by Andy Kramek @ 8/25/2007 12:57:15 PM
RE: _Screen.Property Posted by Ken Murphy @ 8/25/2007 2:11:03 PM
RE: _Screen.Property Posted by Ahsan Rana @ 8/25/2007 7:49:51 PM
RE: _Screen.Property Posted by Marcia Akins @ 8/25/2007 9:15:57 PM
RE: _Screen.Property Posted by Syed Nadeem Iqbal @ 8/26/2007 4:32:33 AM
RE: _Screen.Property Posted by Ken Murphy @ 8/26/2007 2:50:34 PM
RE: _Screen.Property Posted by Benny Thomas @ 8/26/2007 3:37:53 PM
RE: _Screen.Property Posted by Ken Murphy @ 8/26/2007 3:48:51 PM
RE: _Screen.Property Posted by Syed Nadeem Iqbal @ 8/26/2007 7:24:18 PM
RE: _Screen.Property Posted by Marcia Akins @ 8/27/2007 4:19:27 PM
RE: _Screen.Property Posted by Benny Thomas @ 8/26/2007 8:34:50 AM
RE: _Screen.Property Posted by Ken Murphy @ 8/26/2007 2:26:07 PM
RE: _Screen.Property Posted by Marcia Akins @ 8/27/2007 4:22:38 PM
RE: _Screen.Property Posted by Benny Thomas @ 8/26/2007 10:01:16 AM
RE: _Screen.Property Posted by Ken Murphy @ 8/26/2007 2:53:52 PM
RE: _Screen.Property Posted by Marcia Akins @ 8/27/2007 4:24:06 PM
RE: _Screen.Property Posted by Ken Murphy @ 8/27/2007 5:15:36 PM
RE: _Screen.Property Posted by Benny Thomas @ 8/28/2007 8:33:23 AM