************************************************** *-- Class: cproject (d:\projects\yak\common\app\libs\project.vcx) *-- ParentClass: projecthook *-- BaseClass: projecthook *-- Time Stamp: 11/04/08 07:36:03 AM * #INCLUDE "d:\projects\yak\common\include\common.h" * DEFINE CLASS cproject AS projecthook Height = 22 Width = 23 cappclass = "acntapp" cclasslib = "acontainer.vcx" Name = "cproject" * method to update version in a class. PROCEDURE updversion LOCAL lcOldVers, lcNewVers * this holds the class I want to store the version number to. USE (this.cClassLib) * save class before hacking COPY TO acontainerBak LOCATE FOR objname = (this.cappclass) IF NOT EOF() * cclientversion is a propert in my app class lcOldVers = STREXTRACT(properties,'cclientversion =',CHR(13)) lcNewVers = " "+_vfp.ActiveProject.VersionNumber lcNewProp = STRTRAN(properties,lcOldVers,lcNewVers,1,1,1) replace properties WITH lcNewProp USE ENDIF ENDPROC PROCEDURE Init DODEFAULT() IF TYPE("_vfp.ActiveProject.name")<> "U" * DEBUGOUT _vfp.ActiveProject.name lcHomeDir = _vfp.ActiveProject.HomeDir CD (lcHomeDir) _screen.Caption = "Microsoft Visual Foxpro " +_vfp.ActiveProject.name * WAIT WINDOW TIMEOUT 3 _vfp.ActiveProject.name ENDIF IF WEXIST("command") ACTIVATE WINDOW command ENDIF ENDPROC PROCEDURE BeforeBuild LPARAMETERS cOutputName, nBuildAction, lRebuildAll, lShowErrors, lBuildNewGuids DODEFAULT(cOutputName, nBuildAction, lRebuildAll, lShowErrors, lBuildNewGuids) * calls the updVersion method this.updVersion() IF FILE("logsql.dbf") USE logsql EXCLUSIVE ZAP USE ENDIF ENDPROC ENDDEFINE * *-- EndDefine: cproject **************************************************>And I don't know how to that either. (sigh)