Jump to content

yhackup

Members
  • Posts

    8
  • Joined

  • Last visited

Everything posted by yhackup

  1. It worked as I wanted. Thanks let's make it a little more beautiful https://resmim.net/i/3Ui02
  2. bought it a few days ago, the latest version
  3. hello sorry for my english. I am using MYDac TMyDump component in one of my projects. While backing up the database, I can track the progress from the BackupProgress event, but not on unigui form image unit BackupUnit; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, uniGUITypes, uniGUIAbstractClasses, uniGUIClasses, uniGUIForm, DataModules, uniMemo, uniGUIBaseClasses, uniProgressBar, DADump, MyDump, uniButton, uniBitBtn, uniSpeedButton, uniPanel, ServerModule, uniTimer, uniThreadTimer, Data.DB, uniBasicGrid, uniDBGrid, dxmdaset; type TBackupForm = class(TUniForm) MyDump1: TMyDump; UniProgressBar1: TUniProgressBar; UniPanel1: TUniPanel; UniSpeedButton1: TUniSpeedButton; UniMemo1: TUniMemo; procedure MyDump1BackupProgress(Sender: TObject; ObjectName: string; ObjectNum, ObjectCount, Percent: Integer); procedure UniSpeedButton1Click(Sender: TObject); private { Private declarations } public { Public declarations } end; function BackupForm: TBackupForm; implementation {$R *.dfm} uses MainModule, uniGUIApplication; function BackupForm: TBackupForm; begin Result := TBackupForm(UniMainModule.GetFormInstance(TBackupForm)); end; procedure TBackupForm.MyDump1BackupProgress(Sender: TObject; ObjectName: string; ObjectNum, ObjectCount, Percent: Integer); begin UniProgressBar1.Max := ObjectCount * 100; UniProgressBar1.Position := ObjectNum * Percent; UniSession.Synchronize; end; procedure TBackupForm.UniSpeedButton1Click(Sender: TObject); begin if not DirectoryExists(UniServerModule.FilesFolderPath + 'backup\') then CreateDir(UniServerModule.FilesFolderPath + 'backup\'); MyDump1.BackupToFile(UniServerModule.FilesFolderPath + 'backup\' + formatdatetime('hh_nn_ss_dd_mm_yyyy', Now) + '.sql'); end; end.
×
×
  • Create New...