sub gen_rslt { if( $filepath ){ system $pathtobatchfile, '--first', $filepath; } else { $mw->MsgBox( -detail => "select path first", -title => "select path first " )->Show; } }