VERSION 5.00 Begin VB.Form frmSaveSelect BorderStyle = 3 '固定ダイアログ Caption = "保存先選択" ClientHeight = 4110 ClientLeft = 45 ClientTop = 330 ClientWidth = 5175 LinkTopic = "Form2" MaxButton = 0 'False MinButton = 0 'False ScaleHeight = 4110 ScaleWidth = 5175 ShowInTaskbar = 0 'False StartUpPosition = 3 'Windows の既定値 Begin VB.CommandButton cmdNo Caption = "選択しない(&N)" Height = 375 Left = 1560 TabIndex = 6 Top = 3600 Width = 1335 End Begin VB.CommandButton cmdYes Caption = "選択する(&Y)" Default = -1 'True Height = 375 Left = 120 TabIndex = 5 Top = 3600 Width = 1335 End Begin VB.FileListBox File1 Height = 2970 Left = 2640 TabIndex = 4 Top = 480 Width = 2415 End Begin VB.DirListBox Dir1 Height = 2610 Left = 120 TabIndex = 3 Top = 840 Width = 2415 End Begin VB.DriveListBox Drive1 Height = 300 Left = 120 TabIndex = 2 Top = 480 Width = 2415 End Begin VB.TextBox txtFileName Height = 270 Left = 2640 TabIndex = 1 Top = 120 Width = 2415 End Begin VB.Label lblFileName Alignment = 1 '右揃え Caption = "ファイル名(&N):" Height = 255 Left = 120 TabIndex = 0 Top = 120 Width = 2415 End End Attribute VB_Name = "frmSaveSelect" Attribute VB_GlobalNameSpace = False Attribute VB_Creatable = False Attribute VB_PredeclaredId = True Attribute VB_Exposed = False Option Explicit '変数の宣言 Dim ans As String Private Sub cmdNo_Click() '画面表示ウィンドウの切り替え Unload frmSaveSelect frmAnalysis.Show End Sub Private Sub cmdYes_Click() '画面表示ウィンドウの切り替え frmSaveSelect.Hide frmAnalysis.Show End Sub Private Sub Dir1_Change() 'カレントバスの取得 File1.Path = Dir1.Path End Sub Private Sub Drive1_Change() 'カレントドライブの取得 On Error GoTo errhandler Dir1.Path = Drive1.Drive Exit Sub errhandler: If Err.Number = 68 Or Err.Number = 71 Then ans = MsgBox("フロッピーディスクをセットして下さい。", vbExclamation, "フロッピー未搬入") Else ans = MsgBox("予期しないエラーが発生しました。強制終了します。", vbCritical, "強制終了") End End If End Sub Private Sub File1_Click() '選択したファイル名の取得 txtFileName.Text = File1.FileName End Sub