Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to close Class Designer window programmatically
Message
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01066052
Message ID:
01066059
Views:
20
Ok, using today's thread from Fabio I solved it:
*  Program...........: UPDATEPROPERTY.PRG
*  Author............: Nadya Nosonovsky                   
*  Project...........: Visual Collections                 
*  Created...........: 11/07/2005  11:43:24
*  Copyright.........: (c) Jzanus, 2005
*) Description.......: 
*  Calling Samples...: 
*  Parameter List....: 
*  Major change list.: 

LPARAMETERS tcLibrary, tcProperty, tuValue

IF EMPTY(m.tcLibrary)
   tcLibrary = GETFILE('vcx')
ENDIF

IF EMPTY(m.tcProperty)
   tcProperty = "StatusBarText"
ENDIF

IF EMPTY(m.tuValue)      
	tuValue = [" "]
ENDIF

LOCAL laClasses[1], arrObj[1]
LOCAL lnClasses, lnI, loObject

lnClasses =AVCXCLASSES(laClasses, m.tcLibrary)	

FOR lnI =1 TO lnClasses
   MODIFY CLASS (laClasses[m.lnI,1]) OF (m.tcLibrary) nowait
   =ASELOBJ(arrObj,1)
   loObject = arrObj[1]

	IF VARTYPE(m.loObject) = "O"
		IF PEMSTATUS(m.loObject,m.tcProperty,5)		
		   m.loObject.WriteExpression(m.tcProperty, m.tuValue)
*		   STORE m.tuValue TO (m.loObject + "." + m.tcProperty)
		endif   
	ENDIF
        * Code from Fabio Lunardon
	RELEASE loObject
	?? ''
	ACTIVATE WINDOW (WONTOP())
	KEYBOARD '{CTRL+W}' PLAIN
	DOEVENTS FORCE	
 NEXT
      
Thanks, Fabio <g>
If it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform