This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param( | |
$Module ="importexcel" | |
) | |
$proxyCredntial = Get-Credential -Message "Input Proxy User/Password" | |
#Get WebProxy information from internet controlpanel.this method get it in case of proxy auto-config ,too. | |
$SystemProxy = [System.Net.WebRequest]::GetSystemWebProxy() | |
#Access point for Install-PackageProvider cmdlet | |
$URL = "https://go.microsoft.com/fwlink/?LinkID=627338&clcid=0x409" | |
#Get proxy URI for $URL | |
$ProxyUri = $SystemProxy.GetProxy($URL) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
名前 | |
Get-WURebootStatus | |
概要 | |
Windows Updateの再起動ステータスを表示する. | |
構文 | |
Get-WURebootStatus [-Silent] [[-ComputerName] <String[]>] [-AutoReboot] [-WhatIf] [-Confirm] [<CommonParameters>] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
名前 | |
Get-WUInstall | |
概要 | |
更新をダウンロードしてインストールします。 | |
構文 | |
Get-WUInstall [[-UpdateType] <String>] [[-UpdateID] <String []>] [[-RevisionNumber] <Int32>] [[-CategoryIDs] <String []>] [-IsInstalled] [-IsHidden ] [-WithHidden] [[-Criteria] <String>] [-ShowSearchCri | |
条件] [[-RootCategories] <String []>] [[-Category] <String []>] [[-KBArticleID] <String []>] [[-Title] <String>] [[-Severity] < String []>] [[-NotCategory] <String []>] [[-NotKBArticleID] <String []>] [[-N |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ComputerName = $env:COMPUTERNAME | |
$GroupName ="Administrators" | |
$Domain = $env:USERDOMAIN | |
$Account = $env:USERNAME | |
$ADSIUser = [ADSI]("WinNT://$Domain/$Account") | |
$ADSIGroup = [ADSI]("WinNT://$ComputerName/$GroupName") | |
Write-Output "Is $GroupName " $ADSIGroup.IsMember($ADSIUser.AdsPath) | |
#2020/1/6 Virus Scan after the holidays | |
if($ADSIGroup.IsMember($ADSIUser.AdsPath)) { #if user blongs Administrators Group,exec below |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
名前 | |
Import-Excel | |
概要 | |
Create custom objects from the rows in an Excel worksheet. | |
構文 | |
Import-Excel [-Path] <String> [[-WorksheetName] <String>] [-StartRow <Int32>] [-EndRow <Int32>] [-StartColumn <Int32>] [-EndColumn <Int32>] [-Dat |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
名前 | |
Export-Excel | |
概要 | |
Exports data to an Excel worksheet. | |
構文 | |
Export-Excel [[-Path] <String>] [-InputObject <Object>] [-Calculate] [-Show] [-WorksheetName <String>] [-Password <S | |
tring>] [-ClearSheet] [-Append] [-Title <String>] [-TitleFillPattern {None | Solid | DarkGray | MediumGray | LightGr |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ImportExcelをImportする | |
Import-Module ImportExcel | |
#ファイルを保存したフォルダを指定します。 | |
$TargetFolder = C:\Temp | |
#ファイルリストを作ります。 | |
$FileList =Get-ChildItem $TargetFolder -File -Filter *.xlsx | |
#集約させる入れ物を先に用意します。 |