#ディレクトリ取得 $CurrentFolder = Split-Path $MyInvocation.MyCommand.Path -Parent $PSFile1 = $CurrentFolder + "\ConnectNetworkPrinter.ps1" $PSFile2 = $CurrentFolder + "\SetDefaultPrinter.ps1" #PS1実行 .$PSFile1 #PS1実行 .$PSFile2