>oDlg = Createobject("PutFileEx") >? oDlg.PutFile() > >DEFINE CLASS PutFileEx AS form > Left = 100 && Set Dialog Position by positioning the form > Top = 100 && Set Dialog Position > Name = "PutFileEx" > DoCreate = .T. > Visible = .F. > cFileSelected = "" > lUserCancel = .F. > > ADD OBJECT oCDC AS OleControl WITH ; > OleClass = "MsComDlg.CommonDialog" > > PROCEDURE oCDC.Init > This.CancelError = .T. > ENDPROC > > PROCEDURE Error > LPARAMETERS nError, cMethod, nLine > IF nError = 1429 > This.lUserCancel = .T. > ENDIF > ENDPROC > > PROCEDURE PutFile(tnInitColor) > Thisform.oCDC.ShowSave() > IF This.lUserCancel > This.cFileSelected = "" > ELSE > This.cFileSelected = Thisform.oCDC.FileName > ENDIF > RETURN This.cFileSelected > ENDPROC >ENDDEFINE >>>