HELLO

Try this.


PUBLIC ofrmsubclass

ofrmsubclass=NEWOBJECT("frmsubclass")
ofrmsubclass.Show
RETURN


        **************************************************
*-- Form:         frmsubclass
(d:\02workshop\yxerp01\01std\tool\subclass.scx)
*-- ParentClass:  form
*-- BaseClass:    form
*-- Time Stamp:   12/24/06 12:32:04 PM
*
DEFINE CLASS frmsubclass AS form


        Height = 240
        Width = 362
        DoCreate = .T.
        AutoCenter = .T.
        Caption = "Batch SubClass"
        AllowOutput = .F.
        *-- XML Metadata for customizable properties
        _memberdata = ""
        Name = "frmSubClass"


        ADD OBJECT command1 AS commandbutton WITH ;
                Top = 45, ;
                Left = 41, ;
                Height = 22, ;
                Width = 21, ;
                Caption = "...", ;
                TabIndex = 1, ;
                Name = "Command1"


        ADD OBJECT txtsource AS textbox WITH ;
                Enabled = .F., ;
                Height = 23, ;
                Left = 69, ;
                TabIndex = 6, ;
                Top = 46, ;
                Width = 274, ;
                Name = "txtSource"


        ADD OBJECT label1 AS label WITH ;
                AutoSize = .T., ;
                Caption = "Floder contain VCXs", ;
                Height = 17, ;
                Left = 20, ;
                Top = 26, ;
                Width = 113, ;
                TabIndex = 7, ;
                Name = "Label1"


        ADD OBJECT command2 AS commandbutton WITH ;
                Top = 168, ;
                Left = 38, ;
                Height = 22, ;
                Width = 21, ;
                Caption = "...", ;
                TabIndex = 5, ;
                Name = "Command2"


        ADD OBJECT txtdest AS textbox WITH ;
                Enabled = .F., ;
                Height = 23, ;
                Left = 69, ;
                TabIndex = 4, ;
                Top = 169, ;
                Width = 274, ;
                Name = "txtDest"


        ADD OBJECT label2 AS label WITH ;
                AutoSize = .T., ;
                Caption = "Subclass to ", ;
                Height = 17, ;
                Left = 20, ;
                Top = 138, ;
                Width = 70, ;
                TabIndex = 3, ;
                Name = "Label2"


        ADD OBJECT cmdgo AS commandbutton WITH ;
                Top = 201, ;
                Left = 78, ;
                Height = 27, ;
                Width = 84, ;
                Caption = "Go !", ;
                TabIndex = 9, ;
                Name = "cmdGo"


        ADD OBJECT cmdclose AS commandbutton WITH ;
                Top = 200, ;
                Left = 204, ;
                Height = 27, ;
                Width = 84, ;
                Caption = "Close", ;
                TabIndex = 10, ;
                Name = "cmdClose"


        ADD OBJECT txtprefix AS textbox WITH ;
                Format = "T", ;
                Height = 23, ;
                Left = 70, ;
                TabIndex = 2, ;
                Top = 93, ;
                Width = 100, ;
                Name = "txtPrefix"


        ADD OBJECT label3 AS label WITH ;
                AutoSize = .T., ;
                Caption = "prefix", ;
                Height = 17, ;
                Left = 24, ;
                Top = 98, ;
                Width = 31, ;
                TabIndex = 8, ;
                Name = "Label3"


        PROCEDURE command1.Click
                thisform.txtsource.Value=EVL(thisform.txtsource.Value,
SYS(2014,GETDIR()))
        ENDPROC


        PROCEDURE command2.Click
                thisform.txtdest.Value=EVL(thisform.txtdest.Value,
SYS(2014,GETDIR()))
        ENDPROC


        PROCEDURE cmdgo.Click
                LOCAL nVCX,aFile[1],aCls[1],cTmp,nClass

                SET TEXTMERGE ON NOSHOW 

                IF ADIR(aFile,thisform.txtSource.Value + '*.VCX')=0
                        MESSAGEBOX('no class lib found',48)
                        RETURN
                ENDIF   

                FOR nVCX=1 TO ALEN(aFile,1)
                        FOR nClass=1 TO AVCXCLASSES(aCls
,thisform.txtSource.Value + aFile[nVCX,1])
                                CLEAR TYPEAHEAD 

                                TEXT TO cTmp PRETEXT 15 
                                        CREATE CLASS <<aCls[nClass,1]>> OF
<<thisform.txtDest.Value+thisform.txtprefix.Value+JUSTSTEM(aFile[nVCX,1])>>
                                                 as <<aCls[nClass,1]>> FROM
<<thisform.txtSource.Value>><<aFile[nVCX,1]>> NOWAIT 
                                ENDTEXT 
                                &cTmp

                                RELEASE WINDOW "Properties"
                                RELEASE WINDOW "FORM CONTROLS"
                                KEYBOARD '{ctrl+w}' 
                                doevents
                        NEXT 
                NEXT 
                DOEVENTS

                CLEAR TYPEAHEAD 
                MESSAGEBOX('subclass done',64,'')
        ENDPROC


        PROCEDURE cmdclose.Click
                thisform.Release 
        ENDPROC


ENDDEFINE
*
*-- EndDefine: frmsubclass
************************************************** 

-----Original Message-----
From: Vince Teachout [mailto:[EMAIL PROTECTED] 
Sent: Thursday, September 13, 2007 10:15 PM
To: ProFox Email List
Subject: Re: Sub-classing base classes?

[EMAIL PROTECTED] wrote:
> http://leafe.com/archives/showMsg/14717
>   

Kenneth Kixmoeller/fh wrote:
> Here is my version of MakeBase.prg. (It stopped at VFP8 --- just add 
> any new ones from 9 into LBCLASS procedure.)
>   
Thanks, Andrew.  Thanks, Ken.

Where were you guys last night?  I already used Michaels ALanguage
suggestion to write a 10 line program to do the work! 

I'll keep your e-mails, though, for future reference.  Thanks!








_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: http://leafe.com/archives/byMID/profox/[EMAIL PROTECTED]
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to