上一页 1 ··· 55 56 57 58 59 60 61 62 63 ··· 95 下一页
  2014年8月22日
摘要: 创建,显示和删除保存的用户名和密码:cmdkey.exe /add:targetname /user:username /pass:password 阅读全文
posted @ 2014-08-22 09:51 momingliu11 阅读(651) 评论(0) 推荐(0)
摘要: 映射网络路径:1 $net = New-Object -com WScript.Network2 $drive = "Z:"3 $path = "\\$ip\D$"4 $net.mapnetworkdrive($drive, $path, $true, $username, $password) 阅读全文
posted @ 2014-08-22 09:50 momingliu11 阅读(409) 评论(0) 推荐(0)
  2014年8月21日
摘要: Windows2008/2012配置时间同步:w32tm /config /manualpeerlist:"time.youxinpai.com" /syncfromflags:manual /reliable:yes /update查客时间间隔:w32tm /stripchart /compute... 阅读全文
posted @ 2014-08-21 15:45 momingliu11 阅读(3407) 评论(0) 推荐(0)
摘要: 1 $text = "\\127.0.0.1\D$\Hotfix\Hotfix_Win2003\2014-04"2 $pathRoot = [System.IO.Path]::GetPathRoot($text)3 $driverLetter = $pathRoot[-2]4 Join-Path (... 阅读全文
posted @ 2014-08-21 14:37 momingliu11 阅读(192) 评论(0) 推荐(0)
  2014年8月20日
摘要: 在一个button_click下调用了如下外部可执行文件:1 $button1_Click = {2 #TODO: Place custom script here3 .\PsExec.exe \\192.168.10.2 -u testp\administrator -p cm... 阅读全文
posted @ 2014-08-20 23:02 momingliu11 阅读(260) 评论(0) 推荐(0)
摘要: 方法一:1 $UserName = "administrator"2 $serverpass = "pass"3 $server = "10.4.19.60"4 $Password = ConvertTo-SecureString $serverpass -AsPlainText –Force5 $... 阅读全文
posted @ 2014-08-20 22:24 momingliu11 阅读(3765) 评论(1) 推荐(2)
  2014年8月19日
摘要: 创建浏览打开窗口的函数:1 function Read-FolderBrowserDialog([string]$InitialDirectory)2 {3 $app = New-Object -ComObject Shell.Application4 $folder = $app.... 阅读全文
posted @ 2014-08-19 10:55 momingliu11 阅读(545) 评论(0) 推荐(0)
摘要: 展开 modules 属性的详细信息get-process |? {$_.processname -eq "cmd"}|select -ExpandProperty modules不显示某个属性,当参数中也包括 -property 时,-excludeproperty 才有效get-process ... 阅读全文
posted @ 2014-08-19 09:45 momingliu11 阅读(2999) 评论(0) 推荐(0)
  2014年8月18日
摘要: 创建自定义对象 $obj = [pscustomobject]@{a=1;b="";c=$null} % 选择属性列 $obj | gm | % definition ( $obj |gm ).definition $obj | gm |select -ExpandProperty definiti 阅读全文
posted @ 2014-08-18 21:48 momingliu11 阅读(659) 评论(0) 推荐(0)
摘要: $a="a","","b"$a -contains "a" 返回 $true$a -notcontains "a" 返回 $false$a -eq "a" 返回a,此时的返回值是一个 array 阅读全文
posted @ 2014-08-18 17:59 momingliu11 阅读(2406) 评论(0) 推荐(0)
上一页 1 ··· 55 56 57 58 59 60 61 62 63 ··· 95 下一页