Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Marcia Akins
  Where is Marcia Akins?
 Akorn
 Ohio - United States
 Marcia Akins
 To: Nadeem Shah
  Where is Nadeem Shah?
 Rawalpindi
 Pakistan
 Nadeem Shah
 Tags
Subject: RE: Access & assign methods of new property
Thread ID: 155158 Message ID: 155267 # Views: 3 # Ratings: 0
Version: Visual FoxPro 9 Category: Forms
Date: Friday, December 28, 2007 5:04:05 PM         
   


When we create new property then it has to check values
Access method and assign method.

What is the function of these two methods?


In addition to what Ken and Cetin have told you, very often, when performing tasks such as automation (especially when you must make the automation server visible so that the end-user can interact with the final result), you must constantly check to see whether the server is still available because it is possible for the end user to close the visible instance of Word. Putting this type of code in an access method of a form property that holds an object reference to the server can streamline your code quite a bit. For example, if you have a form where you are doing Word automation and you have a form property called oWord that holds an object reference to Word, you would put code like this in oWord_Access:

IF TYPE( 'Thisform.oWord.Name' ) # 'C'
  Thisform.oWord = CREATEOBJECT( 'Word.Application' )
ENDIF
RETURN Thisform.oWord


Regards,
Marcia G. Akins
Tightline Computers, Inc.


ENTIRE THREAD

Access & assign methods of new property Posted by Nadeem Iqbal @ 12/26/2007 2:49:18 PM
RE: Access & assign methods of new property Posted by Ken Murphy @ 12/26/2007 3:48:13 PM
RE: Access & assign methods of new property Posted by Cetin Basoz @ 12/26/2007 5:27:00 PM
RE: Access & assign methods of new property Posted by Nadeem Iqbal @ 12/28/2007 6:52:45 AM
RE: Access & assign methods of new property Posted by Marcia Akins @ 12/28/2007 5:04:05 PM