From 31b72488b20a3c6bdb54419c6fbe02759fe97325 Mon Sep 17 00:00:00 2001 From: "Michael J. Seiferling" Date: Wed, 23 Mar 2016 16:52:03 -0600 Subject: [PATCH 1/5] Test fixes for issue #43 --- GBM/Forms/frmFileFolderSearch.Designer.vb | 43 +++++- GBM/Forms/frmFileFolderSearch.vb | 60 ++++++-- GBM/Forms/frmMain.vb | 52 +++++-- GBM/Managers/mgrBackup.vb | 36 +++-- GBM/Managers/mgrRestore.vb | 175 ++++++++++++---------- GBM/My Project/Resources.Designer.vb | 33 +++- GBM/My Project/Resources.resx | 11 +- 7 files changed, 273 insertions(+), 137 deletions(-) diff --git a/GBM/Forms/frmFileFolderSearch.Designer.vb b/GBM/Forms/frmFileFolderSearch.Designer.vb index ebe0bbd..7b792a6 100644 --- a/GBM/Forms/frmFileFolderSearch.Designer.vb +++ b/GBM/Forms/frmFileFolderSearch.Designer.vb @@ -25,6 +25,9 @@ Partial Class frmFileFolderSearch Me.txtCurrentLocation = New System.Windows.Forms.TextBox() Me.btnCancel = New System.Windows.Forms.Button() Me.bwSearch = New System.ComponentModel.BackgroundWorker() + Me.lstResults = New System.Windows.Forms.ListBox() + Me.btnOk = New System.Windows.Forms.Button() + Me.lblResults = New System.Windows.Forms.Label() Me.SuspendLayout() ' 'txtCurrentLocation @@ -32,16 +35,16 @@ Partial Class frmFileFolderSearch Me.txtCurrentLocation.Location = New System.Drawing.Point(12, 12) Me.txtCurrentLocation.Name = "txtCurrentLocation" Me.txtCurrentLocation.ReadOnly = True - Me.txtCurrentLocation.Size = New System.Drawing.Size(379, 20) + Me.txtCurrentLocation.Size = New System.Drawing.Size(460, 20) Me.txtCurrentLocation.TabIndex = 0 Me.txtCurrentLocation.TabStop = False ' 'btnCancel ' - Me.btnCancel.Location = New System.Drawing.Point(397, 10) + Me.btnCancel.Location = New System.Drawing.Point(397, 114) Me.btnCancel.Name = "btnCancel" Me.btnCancel.Size = New System.Drawing.Size(75, 23) - Me.btnCancel.TabIndex = 0 + Me.btnCancel.TabIndex = 4 Me.btnCancel.Text = "&Cancel" Me.btnCancel.UseVisualStyleBackColor = True ' @@ -49,11 +52,40 @@ Partial Class frmFileFolderSearch ' Me.bwSearch.WorkerSupportsCancellation = True ' + 'lstResults + ' + Me.lstResults.FormattingEnabled = True + Me.lstResults.Location = New System.Drawing.Point(12, 52) + Me.lstResults.Name = "lstResults" + Me.lstResults.Size = New System.Drawing.Size(460, 56) + Me.lstResults.TabIndex = 2 + ' + 'btnOk + ' + Me.btnOk.Location = New System.Drawing.Point(316, 114) + Me.btnOk.Name = "btnOk" + Me.btnOk.Size = New System.Drawing.Size(75, 23) + Me.btnOk.TabIndex = 3 + Me.btnOk.Text = "&OK" + Me.btnOk.UseVisualStyleBackColor = True + ' + 'lblResults + ' + Me.lblResults.AutoSize = True + Me.lblResults.Location = New System.Drawing.Point(9, 36) + Me.lblResults.Name = "lblResults" + Me.lblResults.Size = New System.Drawing.Size(45, 13) + Me.lblResults.TabIndex = 1 + Me.lblResults.Text = "Results:" + ' 'frmFileFolderSearch ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font - Me.ClientSize = New System.Drawing.Size(484, 46) + Me.ClientSize = New System.Drawing.Size(484, 146) + Me.Controls.Add(Me.lblResults) + Me.Controls.Add(Me.btnOk) + Me.Controls.Add(Me.lstResults) Me.Controls.Add(Me.btnCancel) Me.Controls.Add(Me.txtCurrentLocation) Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle @@ -70,4 +102,7 @@ Partial Class frmFileFolderSearch Friend WithEvents txtCurrentLocation As System.Windows.Forms.TextBox Friend WithEvents btnCancel As System.Windows.Forms.Button Friend WithEvents bwSearch As System.ComponentModel.BackgroundWorker + Friend WithEvents lstResults As System.Windows.Forms.ListBox + Friend WithEvents btnOk As System.Windows.Forms.Button + Friend WithEvents lblResults As System.Windows.Forms.Label End Class diff --git a/GBM/Forms/frmFileFolderSearch.vb b/GBM/Forms/frmFileFolderSearch.vb index 8bf3085..e7d09dc 100644 --- a/GBM/Forms/frmFileFolderSearch.vb +++ b/GBM/Forms/frmFileFolderSearch.vb @@ -12,6 +12,7 @@ Public Class frmFileFolderSearch Dim bShutdown As Boolean = False Delegate Sub UpdateInfoCallBack(ByVal sCurrentFolder As String) + Delegate Sub UpdateResultsCallBack(ByVal sItem As String) Public Property GameName As String Get @@ -58,6 +59,15 @@ Public Class frmFileFolderSearch End If End Sub + Private Sub UpdateResults(ByVal sItem As String) + If lstResults.InvokeRequired = True Then + Dim d As New UpdateInfoCallBack(AddressOf UpdateResults) + Me.Invoke(d, New Object() {sItem}) + Else + lstResults.Items.Add(sItem) + End If + End Sub + Private Function SearchDirectory(ByVal dir As DirectoryInfo, ByVal sDirectoryName As String) As String Dim sSubSearch As String = String.Empty Dim sFoundItem As String = String.Empty @@ -77,11 +87,7 @@ Public Class frmFileFolderSearch 'Search Current Directory If dir.GetDirectories(sDirectoryName).Length > 0 Then sFoundItem = dir.FullName & Path.DirectorySeparatorChar & sDirectoryName - If mgrCommon.ShowMessage(mgrPath_ConfirmPathCorrect, New String() {GameName, sFoundItem}, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then - Return sFoundItem - Else - Return String.Empty - End If + UpdateResults(sFoundItem) End If 'Search Sub Directory @@ -90,7 +96,7 @@ Public Class frmFileFolderSearch sSubSearch = SearchDirectory(newDir, sDirectoryName) If sSubSearch <> String.Empty Then Return sSubSearch - End If + End If Next Catch e As System.UnauthorizedAccessException 'Do Nothing @@ -120,11 +126,7 @@ Public Class frmFileFolderSearch 'Search Current Directory If dir.GetFiles(sFileName).Length > 0 Then sFoundItem = Path.GetDirectoryName(dir.FullName & Path.DirectorySeparatorChar & sFileName) - If mgrCommon.ShowMessage(mgrPath_ConfirmPathCorrect, New String() {GameName, sFoundItem}, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then - Return sFoundItem - Else - Return String.Empty - End If + UpdateResults(sFoundItem) End If 'Search Sub Directory @@ -166,16 +168,22 @@ Public Class frmFileFolderSearch If FoundItem = "Cancel" Then FoundItem = String.Empty If oDrives.Count > iCurrentDrive And FoundItem = String.Empty Then - oResult = mgrCommon.ShowMessage(frmFileFolderSearch_SwitchDrives, New String() {oSearchDrive.Root.ToString, oDrives(iCurrentDrive).RootDirectory.ToString}, MsgBoxStyle.YesNo) + oResult = mgrCommon.ShowMessage(frmFileFolderSearch_SwitchDrives, New String() {oDrives(iCurrentDrive).RootDirectory.ToString}, MsgBoxStyle.YesNo) If oResult = MsgBoxResult.Yes Then Search(oDrives(iCurrentDrive)) - Else - bShutdown = True - Me.Close() End If Else + SearchComplete() + End If + End Sub + + Private Sub SearchComplete() + If lstResults.Items.Count = 0 Then bShutdown = True Me.Close() + Else + txtCurrentLocation.Text = frmFileFolderSearch_SearchComplete + lstResults.SelectedIndex = 0 End If End Sub @@ -184,6 +192,8 @@ Public Class frmFileFolderSearch Me.Text = frmFileFolderSearch_FormName 'Set Form Text + lblResults.Text = frmFileFolderSearch_lblResults + btnOk.Text = frmFileFolderSearch_btnOk btnCancel.Text = frmFileFolderSearch_btnCancel End Sub @@ -206,11 +216,29 @@ Public Class frmFileFolderSearch End Sub Private Sub btnCancel_Click(sender As Object, e As EventArgs) Handles btnCancel.Click - bwSearch.CancelAsync() + If bwSearch.IsBusy Then + bwSearch.CancelAsync() + Else + bShutdown = True + Me.Close() + End If End Sub Private Sub frmFileFolderSearch_FormClosing(sender As Object, e As FormClosingEventArgs) Handles MyBase.FormClosing bwSearch.CancelAsync() If Not bShutdown Then e.Cancel = True End Sub + + Private Sub btnOk_Click(sender As Object, e As EventArgs) Handles btnOk.Click + Dim sItem As String + + If lstResults.SelectedItems.Count = 1 Then + sItem = lstResults.SelectedItem.ToString + If mgrCommon.ShowMessage(mgrPath_ConfirmPathCorrect, New String() {GameName, sItem}, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then + FoundItem = sItem + bShutdown = True + Me.Close() + End If + End If + End Sub End Class \ No newline at end of file diff --git a/GBM/Forms/frmMain.vb b/GBM/Forms/frmMain.vb index 21492ae..d5555ab 100644 --- a/GBM/Forms/frmMain.vb +++ b/GBM/Forms/frmMain.vb @@ -146,15 +146,11 @@ Public Class frmMain End Sub Private Sub ExecuteBackup(ByVal oBackupList As List(Of clsGame)) - 'Init Backup Settings - oBackup.Settings = oSettings oBackup.DoBackup(oBackupList) OperationEnded() End Sub - Private Sub ExecuteRestore(ByVal oRestoreList As List(Of clsBackup)) - 'Init Restore Settings - oRestore.Settings = oSettings + Private Sub ExecuteRestore(ByVal oRestoreList As List(Of clsBackup)) oRestore.DoRestore(oRestoreList) OperationEnded() End Sub @@ -165,19 +161,26 @@ Public Class frmMain Dim oReadyList As New List(Of clsBackup) Dim oRestoreInfo As clsBackup Dim bTriggerReload As Boolean = False - + Dim bPathVerified As Boolean eCurrentOperation = eOperation.Restore OperationStarted() 'Build Restore List For Each oGame In oRestoreList + bPathVerified = False oRestoreInfo = oBackupData(oGame.Name) If mgrRestore.CheckPath(oRestoreInfo, oGame, bTriggerReload) Then - oReadyList.Add(oRestoreInfo) + bPathVerified = True Else UpdateLog(mgrCommon.FormatString(frmMain_ErrorRestorePath, oRestoreInfo.Name), False, ToolTipIcon.Error, True) End If + + If bPathVerified Then + If oRestore.CheckRestorePrereq(oRestoreInfo) Then + oReadyList.Add(oRestoreInfo) + End If + End If Next 'Reload the monitor list if any game data was changed during the path checks @@ -197,6 +200,7 @@ Public Class frmMain Private Sub RunManualBackup(ByVal oBackupList As List(Of clsGame)) Dim oGame As clsGame Dim bNoAuto As Boolean + Dim bPathVerified As Boolean Dim oReadyList As New List(Of clsGame) eCurrentOperation = eOperation.Backup @@ -205,6 +209,7 @@ Public Class frmMain 'Build Backup List For Each oGame In oBackupList bNoAuto = False + bPathVerified = False gMonStripStatusButton.Enabled = False UpdateLog(mgrCommon.FormatString(frmMain_ManualBackup, oGame.Name), False) @@ -216,12 +221,18 @@ Public Class frmMain End If If oGame.ProcessPath <> String.Empty Then - oReadyList.Add(oGame) + bPathVerified = True Else - UpdateLog(mgrCommon.FormatString(frmMain_ErrorBackupUnknownPath, oGame.Name), True, ToolTipIcon.Error, True) + UpdateLog(mgrCommon.FormatString(frmMain_ErrorBackupUnknownPath, oGame.Name), False, ToolTipIcon.Error, True) End If Else - oReadyList.Add(oGame) + bPathVerified = True + End If + + If bPathVerified Then + If oBackup.CheckBackupPrereq(oGame) Then + oReadyList.Add(oGame) + End If End If Next @@ -290,7 +301,7 @@ Public Class frmMain SetLastAction(mgrCommon.FormatString(frmMain_ErrorBackupCancel, oProcess.GameInfo.CroppedName)) OperationEnded() End If - End If + End If End If Else bDoBackup = False @@ -300,11 +311,16 @@ Public Class frmMain End If If bDoBackup Then - 'Run the backup - oReadyList.Add(oProcess.GameInfo) - Dim trd As New System.Threading.Thread(AddressOf ExecuteBackup) - trd.IsBackground = True - trd.Start(oReadyList) + If Not oBackup.CheckBackupPrereq(oProcess.GameInfo) Then + SetLastAction(mgrCommon.FormatString(frmMain_ErrorBackupCancel, oProcess.GameInfo.CroppedName)) + OperationEnded() + Else + 'Run the backup + oReadyList.Add(oProcess.GameInfo) + Dim trd As New System.Threading.Thread(AddressOf ExecuteBackup) + trd.IsBackground = True + trd.Start(oReadyList) + End If End If End Sub @@ -684,6 +700,8 @@ Public Class frmMain PauseScan() If frm.ShowDialog() = Windows.Forms.DialogResult.OK Then oSettings = frm.Settings + oBackup.Settings = oSettings + oRestore.Settings = oSettings 'Set Remote Database Location mgrPath.RemoteDatabaseLocation = oSettings.BackupFolder SetupSyncWatcher() @@ -806,6 +824,8 @@ Public Class frmMain 'Load Settings oSettings.LoadSettings() + oBackup.Settings = oSettings + oRestore.Settings = oSettings If Not bFirstRun Then 'The application cannot continue if this fails diff --git a/GBM/Managers/mgrBackup.vb b/GBM/Managers/mgrBackup.vb index f6c5ba8..b5d29e5 100644 --- a/GBM/Managers/mgrBackup.vb +++ b/GBM/Managers/mgrBackup.vb @@ -85,6 +85,28 @@ Public Class mgrBackup End Try End Sub + Public Function CheckBackupPrereq(ByVal oGame As clsGame) As Boolean + Dim sBackupFile As String = oSettings.BackupFolder + If oSettings.CreateSubFolder Then sBackupFile = sBackupFile & Path.DirectorySeparatorChar & oGame.Name + sBackupFile = sBackupFile & Path.DirectorySeparatorChar & oGame.Name & ".7z" + + If mgrRestore.CheckManifest(oGame.Name) Then + If mgrCommon.ShowMessage(mgrBackup_ConfirmManifestConflict, oGame.Name, MsgBoxStyle.YesNo) = MsgBoxResult.No Then + RaiseEvent UpdateLog(mgrBackup_ErrorManifestConflict, False, ToolTipIcon.Error, True) + Return False + End If + End If + + If oSettings.ShowOverwriteWarning And File.Exists(sBackupFile) And Not oGame.AppendTimeStamp Then + If mgrCommon.ShowMessage(mgrBackup_ConfirmOverwrite, MsgBoxStyle.YesNo) = MsgBoxResult.No Then + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorOverwriteAbort, oGame.Name), False, ToolTipIcon.Error, True) + Return False + End If + End If + + Return True + End Function + Public Sub DoBackup(ByVal oBackupList As List(Of clsGame)) Dim oGame As clsGame Dim bDoBackup As Boolean @@ -109,13 +131,6 @@ Public Class mgrBackup CancelOperation = False RaiseEvent UpdateBackupInfo(oGame) - If mgrRestore.CheckManifest(oGame.Name) Then - If mgrCommon.ShowMessage(mgrBackup_ConfirmManifestConflict, oGame.Name, MsgBoxStyle.YesNo) = MsgBoxResult.No Then - RaiseEvent UpdateLog(mgrBackup_ErrorManifestConflict, False, ToolTipIcon.Error, True) - bDoBackup = False - End If - End If - If oSettings.CreateSubFolder Then sBackupFile = sBackupFile & Path.DirectorySeparatorChar & oGame.Name Try @@ -134,13 +149,6 @@ Public Class mgrBackup sBackupFile = sBackupFile & Path.DirectorySeparatorChar & oGame.Name & ".7z" End If - If oSettings.ShowOverwriteWarning And File.Exists(sBackupFile) Then - If mgrCommon.ShowMessage(mgrBackup_ConfirmOverwrite, MsgBoxStyle.YesNo) = MsgBoxResult.No Then - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorOverwriteAbort, oGame.Name), False, ToolTipIcon.Error, True) - bDoBackup = False - End If - End If - If bDoBackup Then If oGame.AbsolutePath = False Then If oGame.Path <> String.Empty Then diff --git a/GBM/Managers/mgrRestore.vb b/GBM/Managers/mgrRestore.vb index 091f06e..95a70cf 100644 --- a/GBM/Managers/mgrRestore.vb +++ b/GBM/Managers/mgrRestore.vb @@ -161,20 +161,64 @@ Public Class mgrRestore Return slRemovedItems End Function + Public Function CheckRestorePrereq(ByVal oBackupInfo As clsBackup) As Boolean + Dim sHash As String + Dim sExtractPath As String + Dim sBackupFile As String = oSettings.BackupFolder & Path.DirectorySeparatorChar & oBackupInfo.FileName + + If oBackupInfo.AbsolutePath Then + sExtractPath = oBackupInfo.RestorePath + Else + sExtractPath = oBackupInfo.RelativeRestorePath + End If + + 'Check if restore location exists, prompt to create if it doesn't. + If Not Directory.Exists(sExtractPath) Then + If mgrCommon.ShowMessage(mgrRestore_ConfirmCreatePath, sExtractPath, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then + Try + Directory.CreateDirectory(sExtractPath) + Catch ex As Exception + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorCreatePath, ex.Message), False, ToolTipIcon.Error, True) + Return False + End Try + Else + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorNoPath, sExtractPath), False, ToolTipIcon.Error, True) + Return False + End If + End If + + 'Check file integrity + If oSettings.CheckSum Then + If oBackupInfo.CheckSum <> String.Empty Then + sHash = mgrHash.Generate_SHA256_Hash(sBackupFile) + If sHash <> oBackupInfo.CheckSum Then + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorFailedCheck, oBackupInfo.Name), False, ToolTipIcon.Info, True) + If mgrCommon.ShowMessage(mgrRestore_ConfirmFailedCheck, oBackupInfo.Name, MsgBoxStyle.YesNo) = MsgBoxResult.No Then + RaiseEvent UpdateLog(mgrRestore_ErrorCheckAbort, False, ToolTipIcon.Info, True) + Return False + End If + Else + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_Verified, oBackupInfo.Name), False, ToolTipIcon.Info, True) + End If + Else + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_NoVerify, oBackupInfo.Name), False, ToolTipIcon.Info, True) + End If + End If + + Return True + End Function + Public Sub DoRestore(ByVal oRestoreList As List(Of clsBackup)) Dim prs7z As Process Dim sBackupFile As String Dim sExtractPath As String - Dim bDoRestore As Boolean Dim bRestoreCompleted As Boolean - Dim sHash As String For Each oBackupInfo In oRestoreList 'Init prs7z = New Process sBackupFile = oSettings.BackupFolder & Path.DirectorySeparatorChar & oBackupInfo.FileName sExtractPath = String.Empty - bDoRestore = True bRestoreCompleted = False CancelOperation = False RaiseEvent UpdateRestoreInfo(oBackupInfo) @@ -185,94 +229,59 @@ Public Class mgrRestore sExtractPath = oBackupInfo.RelativeRestorePath End If - 'Check if restore location exists, prompt to create if it doesn't. - If Not Directory.Exists(sExtractPath) Then - If mgrCommon.ShowMessage(mgrRestore_ConfirmCreatePath, sExtractPath, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then - Try - Directory.CreateDirectory(sExtractPath) - Catch ex As Exception - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorCreatePath, ex.Message), False, ToolTipIcon.Error, True) - bDoRestore = False - End Try - Else - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorNoPath, sExtractPath), False, ToolTipIcon.Error, True) - bDoRestore = False - End If - End If - - 'Check file integrity - If oSettings.CheckSum Then - If oBackupInfo.CheckSum <> String.Empty Then - sHash = mgrHash.Generate_SHA256_Hash(sBackupFile) - If sHash <> oBackupInfo.CheckSum Then - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorFailedCheck, oBackupInfo.Name), False, ToolTipIcon.Info, True) - If mgrCommon.ShowMessage(mgrRestore_ConfirmFailedCheck, oBackupInfo.Name, MsgBoxStyle.YesNo) = MsgBoxResult.No Then - RaiseEvent UpdateLog(mgrRestore_ErrorCheckAbort, False, ToolTipIcon.Info, True) - bDoRestore = False - End If + Try + If File.Exists(sBackupFile) Then + If mgrCommon.IsUnix Then + prs7z.StartInfo.Arguments = "x """ & sBackupFile & """ -o""" & sExtractPath & Path.DirectorySeparatorChar & """ -aoa -r" Else - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_Verified, oBackupInfo.Name), False, ToolTipIcon.Info, True) + prs7z.StartInfo.Arguments = "x -bb1 -bt """ & sBackupFile & """ -o""" & sExtractPath & Path.DirectorySeparatorChar & """ -aoa -r" End If - Else - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_NoVerify, oBackupInfo.Name), False, ToolTipIcon.Info, True) - End If - End If - - If bDoRestore Then - Try - If File.Exists(sBackupFile) Then - If mgrCommon.IsUnix Then - prs7z.StartInfo.Arguments = "x """ & sBackupFile & """ -o""" & sExtractPath & Path.DirectorySeparatorChar & """ -aoa -r" + prs7z.StartInfo.FileName = mgrPath.Utility7zLocation + prs7z.StartInfo.UseShellExecute = False + prs7z.StartInfo.RedirectStandardOutput = True + prs7z.StartInfo.CreateNoWindow = True + prs7z.Start() + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_RestoreInProgress, sExtractPath), False, ToolTipIcon.Info, True) + While Not prs7z.StandardOutput.EndOfStream + If CancelOperation Then + prs7z.Kill() + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorFullAbort, oBackupInfo.Name), True, ToolTipIcon.Error, True) + Exit While + End If + RaiseEvent UpdateLog(prs7z.StandardOutput.ReadLine, False, ToolTipIcon.Info, False) + End While + prs7z.WaitForExit() + If Not CancelOperation Then + If prs7z.ExitCode = 0 Then + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_RestoreComplete, oBackupInfo.Name), False, ToolTipIcon.Info, True) + bRestoreCompleted = True Else - prs7z.StartInfo.Arguments = "x -bb1 -bt """ & sBackupFile & """ -o""" & sExtractPath & Path.DirectorySeparatorChar & """ -aoa -r" + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_RestoreWarnings, oBackupInfo.Name), True, ToolTipIcon.Warning, True) + bRestoreCompleted = False End If - prs7z.StartInfo.FileName = mgrPath.Utility7zLocation - prs7z.StartInfo.UseShellExecute = False - prs7z.StartInfo.RedirectStandardOutput = True - prs7z.StartInfo.CreateNoWindow = True - prs7z.Start() - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_RestoreInProgress, sExtractPath), False, ToolTipIcon.Info, True) - While Not prs7z.StandardOutput.EndOfStream - If CancelOperation Then - prs7z.Kill() - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorFullAbort, oBackupInfo.Name), True, ToolTipIcon.Error, True) - Exit While - End If - RaiseEvent UpdateLog(prs7z.StandardOutput.ReadLine, False, ToolTipIcon.Info, False) - End While - prs7z.WaitForExit() - If Not CancelOperation Then - If prs7z.ExitCode = 0 Then - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_RestoreComplete, oBackupInfo.Name), False, ToolTipIcon.Info, True) - bRestoreCompleted = True - Else - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_RestoreWarnings, oBackupInfo.Name), True, ToolTipIcon.Warning, True) - bRestoreCompleted = False - End If - End If - prs7z.Dispose() - Else - RaiseEvent UpdateLog(mgrRestore_ErrorNoBackup, True, ToolTipIcon.Error, True) End If - - If bRestoreCompleted Then - 'Save Local Manifest - If mgrManifest.DoManifestCheck(oBackupInfo.Name, mgrSQLite.Database.Local) Then - mgrManifest.DoManifestUpdate(oBackupInfo, mgrSQLite.Database.Local) - Else - mgrManifest.DoManifestAdd(oBackupInfo, mgrSQLite.Database.Local) - End If - End If - Catch ex As Exception - RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorOtherFailure, ex.Message), False, ToolTipIcon.Error, True) - End Try + prs7z.Dispose() + Else + RaiseEvent UpdateLog(mgrRestore_ErrorNoBackup, True, ToolTipIcon.Error, True) + End If If bRestoreCompleted Then - RaiseEvent SetLastAction(mgrCommon.FormatString(mgrRestore_ActionComplete, oBackupInfo.CroppedName)) - Else - RaiseEvent SetLastAction(mgrCommon.FormatString(mgrRestore_ActionFailed, oBackupInfo.CroppedName)) + 'Save Local Manifest + If mgrManifest.DoManifestCheck(oBackupInfo.Name, mgrSQLite.Database.Local) Then + mgrManifest.DoManifestUpdate(oBackupInfo, mgrSQLite.Database.Local) + Else + mgrManifest.DoManifestAdd(oBackupInfo, mgrSQLite.Database.Local) + End If End If - End If + Catch ex As Exception + RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorOtherFailure, ex.Message), False, ToolTipIcon.Error, True) + End Try + + If bRestoreCompleted Then + RaiseEvent SetLastAction(mgrCommon.FormatString(mgrRestore_ActionComplete, oBackupInfo.CroppedName)) + Else + RaiseEvent SetLastAction(mgrCommon.FormatString(mgrRestore_ActionFailed, oBackupInfo.CroppedName)) + End If Next End Sub diff --git a/GBM/My Project/Resources.Designer.vb b/GBM/My Project/Resources.Designer.vb index 6a5913d..a0c476b 100644 --- a/GBM/My Project/Resources.Designer.vb +++ b/GBM/My Project/Resources.Designer.vb @@ -834,6 +834,15 @@ Namespace My.Resources End Get End Property + ''' + ''' Looks up a localized string similar to &OK. + ''' + Friend ReadOnly Property frmFileFolderSearch_btnOk() As String + Get + Return ResourceManager.GetString("frmFileFolderSearch_btnOk", resourceCulture) + End Get + End Property + ''' ''' Looks up a localized string similar to Search. ''' @@ -842,16 +851,34 @@ Namespace My.Resources Return ResourceManager.GetString("frmFileFolderSearch_FormName", resourceCulture) End Get End Property - + ''' - ''' Looks up a localized string similar to The location was not found on the [PARAM] drive. Do you wish to search the [PARAM] drive?. + ''' Looks up a localized string similar to Results:. + ''' + Friend ReadOnly Property frmFileFolderSearch_lblResults() As String + Get + Return ResourceManager.GetString("frmFileFolderSearch_lblResults", resourceCulture) + End Get + End Property + + ''' + ''' Looks up a localized string similar to Search Complete!. + ''' + Friend ReadOnly Property frmFileFolderSearch_SearchComplete() As String + Get + Return ResourceManager.GetString("frmFileFolderSearch_SearchComplete", resourceCulture) + End Get + End Property + + ''' + ''' Looks up a localized string similar to Do you wish to search the [PARAM] drive?. ''' Friend ReadOnly Property frmFileFolderSearch_SwitchDrives() As String Get Return ResourceManager.GetString("frmFileFolderSearch_SwitchDrives", resourceCulture) End Get End Property - + ''' ''' Looks up a localized string similar to >. ''' diff --git a/GBM/My Project/Resources.resx b/GBM/My Project/Resources.resx index 15fdc21..3d1fb5d 100644 --- a/GBM/My Project/Resources.resx +++ b/GBM/My Project/Resources.resx @@ -890,7 +890,7 @@ Search - The location was not found on the [PARAM] drive. Do you wish to search the [PARAM] drive? + Do you wish to search the [PARAM] drive? > @@ -1585,4 +1585,13 @@ at [PARAM]. + + &OK + + + Results: + + + Search Complete! + \ No newline at end of file From 83df2edc9032fd31376812373610f26d06c8fdd1 Mon Sep 17 00:00:00 2001 From: "Michael J. Seiferling" Date: Wed, 23 Mar 2016 17:13:15 -0600 Subject: [PATCH 2/5] Hide duplicate search results --- GBM/Forms/frmFileFolderSearch.vb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/GBM/Forms/frmFileFolderSearch.vb b/GBM/Forms/frmFileFolderSearch.vb index e7d09dc..10e1ffc 100644 --- a/GBM/Forms/frmFileFolderSearch.vb +++ b/GBM/Forms/frmFileFolderSearch.vb @@ -64,7 +64,10 @@ Public Class frmFileFolderSearch Dim d As New UpdateInfoCallBack(AddressOf UpdateResults) Me.Invoke(d, New Object() {sItem}) Else - lstResults.Items.Add(sItem) + 'It's possible the same location will be searched twice when using Linux. Filter out duplicate results + If Not lstResults.Items.Contains(sItem) Then + lstResults.Items.Add(sItem) + End If End If End Sub From b458b89b46183f548022b60ee5b4496e41d8b55b Mon Sep 17 00:00:00 2001 From: "Michael J. Seiferling" Date: Thu, 24 Mar 2016 12:24:54 -0600 Subject: [PATCH 3/5] Minor search and builder fix --- GBM/Forms/frmFileFolderSearch.Designer.vb | 6 +++--- GBM/Forms/frmFileFolderSearch.vb | 16 +++++++++------- GBM/Forms/frmIncludeExclude.vb | 4 ++++ GBM/My Project/Resources.Designer.vb | 12 ++++++------ GBM/My Project/Resources.resx | 2 +- 5 files changed, 23 insertions(+), 17 deletions(-) diff --git a/GBM/Forms/frmFileFolderSearch.Designer.vb b/GBM/Forms/frmFileFolderSearch.Designer.vb index 7b792a6..4f3ab2e 100644 --- a/GBM/Forms/frmFileFolderSearch.Designer.vb +++ b/GBM/Forms/frmFileFolderSearch.Designer.vb @@ -71,12 +71,12 @@ Partial Class frmFileFolderSearch ' 'lblResults ' - Me.lblResults.AutoSize = True Me.lblResults.Location = New System.Drawing.Point(9, 36) Me.lblResults.Name = "lblResults" - Me.lblResults.Size = New System.Drawing.Size(45, 13) + Me.lblResults.Size = New System.Drawing.Size(463, 13) Me.lblResults.TabIndex = 1 - Me.lblResults.Text = "Results:" + Me.lblResults.Text = "Search Results" + Me.lblResults.TextAlign = System.Drawing.ContentAlignment.MiddleCenter ' 'frmFileFolderSearch ' diff --git a/GBM/Forms/frmFileFolderSearch.vb b/GBM/Forms/frmFileFolderSearch.vb index 10e1ffc..6bc475d 100644 --- a/GBM/Forms/frmFileFolderSearch.vb +++ b/GBM/Forms/frmFileFolderSearch.vb @@ -168,15 +168,17 @@ Public Class frmFileFolderSearch Private Sub EndSearch() Dim oResult As MsgBoxResult - If FoundItem = "Cancel" Then FoundItem = String.Empty + If Not bShutdown Then + If FoundItem = "Cancel" Then FoundItem = String.Empty - If oDrives.Count > iCurrentDrive And FoundItem = String.Empty Then - oResult = mgrCommon.ShowMessage(frmFileFolderSearch_SwitchDrives, New String() {oDrives(iCurrentDrive).RootDirectory.ToString}, MsgBoxStyle.YesNo) - If oResult = MsgBoxResult.Yes Then - Search(oDrives(iCurrentDrive)) + If oDrives.Count > iCurrentDrive And FoundItem = String.Empty Then + oResult = mgrCommon.ShowMessage(frmFileFolderSearch_SwitchDrives, New String() {oDrives(iCurrentDrive).RootDirectory.ToString}, MsgBoxStyle.YesNo) + If oResult = MsgBoxResult.Yes Then + Search(oDrives(iCurrentDrive)) + End If + Else + SearchComplete() End If - Else - SearchComplete() End If End Sub diff --git a/GBM/Forms/frmIncludeExclude.vb b/GBM/Forms/frmIncludeExclude.vb index 827a346..154f6e6 100644 --- a/GBM/Forms/frmIncludeExclude.vb +++ b/GBM/Forms/frmIncludeExclude.vb @@ -335,6 +335,10 @@ Public Class frmIncludeExclude Private Sub lstBuilder_AfterLabelEdit(sender As Object, e As LabelEditEventArgs) Handles lstBuilder.AfterLabelEdit If Not e.Label Is Nothing Then + If e.Label = String.Empty Then + e.CancelEdit = True + End If + If lstBuilder.Items.ContainsKey(e.Label) Then e.CancelEdit = True Else diff --git a/GBM/My Project/Resources.Designer.vb b/GBM/My Project/Resources.Designer.vb index a0c476b..4c3b60a 100644 --- a/GBM/My Project/Resources.Designer.vb +++ b/GBM/My Project/Resources.Designer.vb @@ -842,7 +842,7 @@ Namespace My.Resources Return ResourceManager.GetString("frmFileFolderSearch_btnOk", resourceCulture) End Get End Property - + ''' ''' Looks up a localized string similar to Search. ''' @@ -851,16 +851,16 @@ Namespace My.Resources Return ResourceManager.GetString("frmFileFolderSearch_FormName", resourceCulture) End Get End Property - + ''' - ''' Looks up a localized string similar to Results:. + ''' Looks up a localized string similar to Search Results. ''' Friend ReadOnly Property frmFileFolderSearch_lblResults() As String Get Return ResourceManager.GetString("frmFileFolderSearch_lblResults", resourceCulture) End Get End Property - + ''' ''' Looks up a localized string similar to Search Complete!. ''' @@ -869,7 +869,7 @@ Namespace My.Resources Return ResourceManager.GetString("frmFileFolderSearch_SearchComplete", resourceCulture) End Get End Property - + ''' ''' Looks up a localized string similar to Do you wish to search the [PARAM] drive?. ''' @@ -878,7 +878,7 @@ Namespace My.Resources Return ResourceManager.GetString("frmFileFolderSearch_SwitchDrives", resourceCulture) End Get End Property - + ''' ''' Looks up a localized string similar to >. ''' diff --git a/GBM/My Project/Resources.resx b/GBM/My Project/Resources.resx index 3d1fb5d..c879fe8 100644 --- a/GBM/My Project/Resources.resx +++ b/GBM/My Project/Resources.resx @@ -1589,7 +1589,7 @@ &OK - Results: + Search Results Search Complete! From b149a19a8b35b9af0ebb03fd542c4118acfc3112 Mon Sep 17 00:00:00 2001 From: "Michael J. Seiferling" Date: Thu, 24 Mar 2016 15:46:33 -0600 Subject: [PATCH 4/5] Added drive selector to search --- GBM/Forms/frmFileFolderSearch.Designer.vb | 28 ++++-- GBM/Forms/frmFileFolderSearch.vb | 101 ++++++++++++++++------ GBM/My Project/Resources.Designer.vb | 9 ++ GBM/My Project/Resources.resx | 3 + 4 files changed, 108 insertions(+), 33 deletions(-) diff --git a/GBM/Forms/frmFileFolderSearch.Designer.vb b/GBM/Forms/frmFileFolderSearch.Designer.vb index 4f3ab2e..8d10947 100644 --- a/GBM/Forms/frmFileFolderSearch.Designer.vb +++ b/GBM/Forms/frmFileFolderSearch.Designer.vb @@ -28,20 +28,21 @@ Partial Class frmFileFolderSearch Me.lstResults = New System.Windows.Forms.ListBox() Me.btnOk = New System.Windows.Forms.Button() Me.lblResults = New System.Windows.Forms.Label() + Me.cboDrive = New System.Windows.Forms.ComboBox() Me.SuspendLayout() ' 'txtCurrentLocation ' - Me.txtCurrentLocation.Location = New System.Drawing.Point(12, 12) + Me.txtCurrentLocation.Location = New System.Drawing.Point(102, 13) Me.txtCurrentLocation.Name = "txtCurrentLocation" Me.txtCurrentLocation.ReadOnly = True - Me.txtCurrentLocation.Size = New System.Drawing.Size(460, 20) + Me.txtCurrentLocation.Size = New System.Drawing.Size(370, 20) Me.txtCurrentLocation.TabIndex = 0 Me.txtCurrentLocation.TabStop = False ' 'btnCancel ' - Me.btnCancel.Location = New System.Drawing.Point(397, 114) + Me.btnCancel.Location = New System.Drawing.Point(397, 146) Me.btnCancel.Name = "btnCancel" Me.btnCancel.Size = New System.Drawing.Size(75, 23) Me.btnCancel.TabIndex = 4 @@ -55,14 +56,14 @@ Partial Class frmFileFolderSearch 'lstResults ' Me.lstResults.FormattingEnabled = True - Me.lstResults.Location = New System.Drawing.Point(12, 52) + Me.lstResults.Location = New System.Drawing.Point(12, 58) Me.lstResults.Name = "lstResults" - Me.lstResults.Size = New System.Drawing.Size(460, 56) + Me.lstResults.Size = New System.Drawing.Size(460, 82) Me.lstResults.TabIndex = 2 ' 'btnOk ' - Me.btnOk.Location = New System.Drawing.Point(316, 114) + Me.btnOk.Location = New System.Drawing.Point(316, 146) Me.btnOk.Name = "btnOk" Me.btnOk.Size = New System.Drawing.Size(75, 23) Me.btnOk.TabIndex = 3 @@ -71,18 +72,28 @@ Partial Class frmFileFolderSearch ' 'lblResults ' - Me.lblResults.Location = New System.Drawing.Point(9, 36) + Me.lblResults.Location = New System.Drawing.Point(9, 42) Me.lblResults.Name = "lblResults" Me.lblResults.Size = New System.Drawing.Size(463, 13) Me.lblResults.TabIndex = 1 Me.lblResults.Text = "Search Results" Me.lblResults.TextAlign = System.Drawing.ContentAlignment.MiddleCenter ' + 'cboDrive + ' + Me.cboDrive.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList + Me.cboDrive.FormattingEnabled = True + Me.cboDrive.Location = New System.Drawing.Point(12, 12) + Me.cboDrive.Name = "cboDrive" + Me.cboDrive.Size = New System.Drawing.Size(85, 21) + Me.cboDrive.TabIndex = 5 + ' 'frmFileFolderSearch ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font - Me.ClientSize = New System.Drawing.Size(484, 146) + Me.ClientSize = New System.Drawing.Size(484, 181) + Me.Controls.Add(Me.cboDrive) Me.Controls.Add(Me.lblResults) Me.Controls.Add(Me.btnOk) Me.Controls.Add(Me.lstResults) @@ -105,4 +116,5 @@ Partial Class frmFileFolderSearch Friend WithEvents lstResults As System.Windows.Forms.ListBox Friend WithEvents btnOk As System.Windows.Forms.Button Friend WithEvents lblResults As System.Windows.Forms.Label + Friend WithEvents cboDrive As System.Windows.Forms.ComboBox End Class diff --git a/GBM/Forms/frmFileFolderSearch.vb b/GBM/Forms/frmFileFolderSearch.vb index 6bc475d..289754d 100644 --- a/GBM/Forms/frmFileFolderSearch.vb +++ b/GBM/Forms/frmFileFolderSearch.vb @@ -4,13 +4,22 @@ Imports System.IO Public Class frmFileFolderSearch Private sSearchItem As String Private sGameName As String = String.Empty + Private bIsLoading As Boolean Private bIsFolder As Boolean Private sFoundItem As String Private oDrives As List(Of DriveInfo) - Private iCurrentDrive As Integer Private oSearchDrive As DirectoryInfo Dim bShutdown As Boolean = False + Private Enum eStopStatus As Integer + Cancel = 1 + ChangeDrive = 2 + FoundResult = 3 + FinishedDrive = 4 + End Enum + + Private iStopStatus As eStopStatus + Delegate Sub UpdateInfoCallBack(ByVal sCurrentFolder As String) Delegate Sub UpdateResultsCallBack(ByVal sItem As String) @@ -151,43 +160,58 @@ Public Class frmFileFolderSearch End Function Private Sub GetDrives() + Dim oComboItems As New List(Of KeyValuePair(Of Integer, String)) + Dim iCount As Integer = 0 + + 'cboDrive + cboDrive.ValueMember = "Key" + cboDrive.DisplayMember = "Value" + oDrives = New List(Of DriveInfo) For Each oDrive As DriveInfo In My.Computer.FileSystem.Drives If oDrive.DriveType = IO.DriveType.Fixed Then oDrives.Add(oDrive) + oComboItems.Add(New KeyValuePair(Of Integer, String)(iCount, oDrive.RootDirectory.ToString)) + iCount += 1 End If Next + cboDrive.DataSource = oComboItems End Sub Private Sub Search(ByVal oDrive As DriveInfo) + iStopStatus = eStopStatus.FinishedDrive oSearchDrive = oDrive.RootDirectory bwSearch.RunWorkerAsync() - iCurrentDrive += 1 End Sub Private Sub EndSearch() - Dim oResult As MsgBoxResult + If FoundItem = "Cancel" Then FoundItem = String.Empty - If Not bShutdown Then - If FoundItem = "Cancel" Then FoundItem = String.Empty - - If oDrives.Count > iCurrentDrive And FoundItem = String.Empty Then - oResult = mgrCommon.ShowMessage(frmFileFolderSearch_SwitchDrives, New String() {oDrives(iCurrentDrive).RootDirectory.ToString}, MsgBoxStyle.YesNo) - If oResult = MsgBoxResult.Yes Then - Search(oDrives(iCurrentDrive)) + Select Case iStopStatus + Case eStopStatus.Cancel + SearchComplete(frmFileFolderSearch_SearchCancel) + Case eStopStatus.ChangeDrive + Search(oDrives(cboDrive.SelectedValue)) + Case eStopStatus.FinishedDrive + 'Attempt to move onto the next drive it one exists and there's been no results + If oDrives.Count > 1 And lstResults.Items.Count = 0 Then + If cboDrive.SelectedIndex = (cboDrive.Items.Count - 1) Then + cboDrive.SelectedIndex = 0 + Else + cboDrive.SelectedIndex = cboDrive.SelectedIndex + 1 + End If + Else + SearchComplete(frmFileFolderSearch_SearchComplete) End If - Else - SearchComplete() - End If - End If + Case eStopStatus.FoundResult + bShutdown = True + Me.Close() + End Select End Sub - Private Sub SearchComplete() - If lstResults.Items.Count = 0 Then - bShutdown = True - Me.Close() - Else - txtCurrentLocation.Text = frmFileFolderSearch_SearchComplete + Private Sub SearchComplete(ByVal sStopMessage As String) + txtCurrentLocation.Text = sStopMessage + If lstResults.Items.Count > 0 Then lstResults.SelectedIndex = 0 End If End Sub @@ -203,9 +227,11 @@ Public Class frmFileFolderSearch End Sub Private Sub frmFileFolderSearch_Load(sender As Object, e As EventArgs) Handles MyBase.Load + bIsLoading = True SetForm() GetDrives() - Search(oDrives(iCurrentDrive)) + bIsLoading = False + Search(oDrives(0)) End Sub Private Sub bwSearch_DoWork(sender As Object, e As System.ComponentModel.DoWorkEventArgs) Handles bwSearch.DoWork @@ -222,6 +248,7 @@ Public Class frmFileFolderSearch Private Sub btnCancel_Click(sender As Object, e As EventArgs) Handles btnCancel.Click If bwSearch.IsBusy Then + iStopStatus = eStopStatus.Cancel bwSearch.CancelAsync() Else bShutdown = True @@ -229,8 +256,7 @@ Public Class frmFileFolderSearch End If End Sub - Private Sub frmFileFolderSearch_FormClosing(sender As Object, e As FormClosingEventArgs) Handles MyBase.FormClosing - bwSearch.CancelAsync() + Private Sub frmFileFolderSearch_FormClosing(sender As Object, e As FormClosingEventArgs) Handles MyBase.FormClosing If Not bShutdown Then e.Cancel = True End Sub @@ -241,8 +267,33 @@ Public Class frmFileFolderSearch sItem = lstResults.SelectedItem.ToString If mgrCommon.ShowMessage(mgrPath_ConfirmPathCorrect, New String() {GameName, sItem}, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then FoundItem = sItem - bShutdown = True - Me.Close() + If bwSearch.IsBusy Then + iStopStatus = eStopStatus.FoundResult + bwSearch.CancelAsync() + Else + bShutdown = True + Me.Close() + End If + End If + End If + End Sub + + Private Sub cboDrive_SelectedIndexChanged(sender As Object, e As EventArgs) Handles cboDrive.SelectedIndexChanged + If Not bIsLoading Then + Dim oResult As MsgBoxResult + + oResult = mgrCommon.ShowMessage(frmFileFolderSearch_SwitchDrives, New String() {oDrives(cboDrive.SelectedValue).RootDirectory.ToString}, MsgBoxStyle.YesNo) + + If oResult = MsgBoxResult.Yes Then + If bwSearch.IsBusy Then + iStopStatus = eStopStatus.ChangeDrive + bwSearch.CancelAsync() + Else + Search(oDrives(cboDrive.SelectedValue)) + End If + Else + iStopStatus = eStopStatus.FinishedDrive + SearchComplete(frmFileFolderSearch_SearchCancel) End If End If End Sub diff --git a/GBM/My Project/Resources.Designer.vb b/GBM/My Project/Resources.Designer.vb index 4c3b60a..6538c3e 100644 --- a/GBM/My Project/Resources.Designer.vb +++ b/GBM/My Project/Resources.Designer.vb @@ -861,6 +861,15 @@ Namespace My.Resources End Get End Property + ''' + ''' Looks up a localized string similar to Search Aborted!. + ''' + Friend ReadOnly Property frmFileFolderSearch_SearchCancel() As String + Get + Return ResourceManager.GetString("frmFileFolderSearch_SearchCancel", resourceCulture) + End Get + End Property + ''' ''' Looks up a localized string similar to Search Complete!. ''' diff --git a/GBM/My Project/Resources.resx b/GBM/My Project/Resources.resx index c879fe8..83ee2db 100644 --- a/GBM/My Project/Resources.resx +++ b/GBM/My Project/Resources.resx @@ -1594,4 +1594,7 @@ Search Complete! + + Search Aborted! + \ No newline at end of file From d1ca0a150e8c4c1d1c16eb0546e5a63a4727e4bb Mon Sep 17 00:00:00 2001 From: "Michael J. Seiferling" Date: Thu, 24 Mar 2016 17:45:02 -0600 Subject: [PATCH 5/5] Alignment fix on search form --- GBM/Forms/frmFileFolderSearch.Designer.vb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GBM/Forms/frmFileFolderSearch.Designer.vb b/GBM/Forms/frmFileFolderSearch.Designer.vb index 8d10947..83e796f 100644 --- a/GBM/Forms/frmFileFolderSearch.Designer.vb +++ b/GBM/Forms/frmFileFolderSearch.Designer.vb @@ -83,7 +83,7 @@ Partial Class frmFileFolderSearch ' Me.cboDrive.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList Me.cboDrive.FormattingEnabled = True - Me.cboDrive.Location = New System.Drawing.Point(12, 12) + Me.cboDrive.Location = New System.Drawing.Point(12, 13) Me.cboDrive.Name = "cboDrive" Me.cboDrive.Size = New System.Drawing.Size(85, 21) Me.cboDrive.TabIndex = 5