腾讯云
开发者社区
文档
建议反馈
控制台
登录/注册
首页
学习
活动
专区
工具
TVP
最新优惠活动
文章/答案/技术大牛
搜索
搜索
关闭
发布
精选内容/技术社群/优惠产品,
尽在小程序
立即前往
文章
问答
(9999+)
视频
沙龙
2
回答
通过powershell删除默认Windows 10应用程序时需要帮助
、
、
下面是我的脚本:Get-AppxPackage -AllUsers |
where-object
–like “*windowsmap*”} | Remove-AppxPackage Get-AppxPackage -AllUser
浏览 2
提问于2017-08-15
得票数 1
回答已采纳
1
回答
powershell -从本地服务器获得最后一次用户登录
-notlike "*ssi1*"}|
Where-Object
{$_.Name -notlike "*ssi3*"}|
Where-Object
{$_.Name -notlike "*ssi5*"}|
Where-Object
{$_.N
浏览 1
提问于2017-09-27
得票数 0
回答已采纳
1
回答
powershell脚本没有正确解释文件路径
{$_.Name -notin $excludes} |
Where-Object
{$_.FullName -like 'Desktop'} | Copy-Item -Destination $dest-Recurse -ErrorAction SilentlyContinue Get-ChildItem -Path $folder
浏览 5
提问于2022-07-09
得票数 -4
1
回答
从数组中动态删除项
、
我使用
where-object
to根据Type属性选择项目。我的问题是,遍历这些项需要相当长的时间,如果我可以从数组中删除我刚刚选择的项,那么会更容易,这样对于下一个对象,数组就会更小。这就是我要做的:'prosess ItemType 2' 问题是,每次我必须再次迭代$items,而不是迭代上一次
where-o
浏览 0
提问于2012-10-19
得票数 0
回答已采纳
2
回答
使用Get-WinEvent查询忽略来自特定源的certein事件ID
、
、
Get-WinEvent -Oldest -FilterHashtable @{Path="20210317_system - Copy.evt" ;Level= 2,3} |
Where-Object
{$_.ID -ne "4"} |
Where-Object
{$_.ID -ne "36"} |
Where-Object
{$_.ID -ne "1111"} |
Where-Object
{$_.ID -ne "2004&qu
浏览 7
提问于2021-03-22
得票数 0
回答已采纳
2
回答
如何用$_替换字符为PowerShell
get-vm |
Where-Object
{$\_.IsClustered -eq $False} |
Where-Object
{$\_.State -eq 'Running'} | ForEach-Object{ $old = [regex]::Escape(' get-vm |
Where-Object
{$_.IsClustered -eq $False}| ForEach-Object {') $new = "
浏览 0
提问于2019-07-25
得票数 1
回答已采纳
1
回答
PowerShell:使用禁用字符列表过滤文件名列表
\FILES.CSV $csvExport = $csvexport + ($csv | select name,length |
Where-Object
{$_.name -like+ ($csv | select name,length |
Where-Object
{$_.name -li
浏览 2
提问于2017-03-09
得票数 0
回答已采纳
2
回答
将管道cmdlet输出到变量和csv文件中
-like "*-*"} |
Where-Object
{$_.name -NotLike "*-NONE"} |
Where-Object
{$_.name -NotLike "*-BLACKBAUD"} | <e
浏览 1
提问于2018-04-17
得票数 0
回答已采纳
1
回答
在PowerShell中将表达式输出到变量中
、
{$_.name -like "*-*"} | '$command+= '
Where-Object
{$_.name -NotLike "*-NONE"} | '$c
浏览 1
提问于2018-04-17
得票数 0
回答已采纳
1
回答
如何在调用“删除项”之前排除特定文件?
、
、
我现在确定如何将$exclude包含在
Where-Object
字段中。want to see what files/folders will be deleted before> Get-ChildItem -Path $path -Recurse -Force |
Where-Object
{ $_.PSIsContainer -and (Get-ChildItem -Path $_.FullName -Recurse -Force |
Where-Object
{ !$_.PSIsContainer }) -eq $nu
浏览 3
提问于2016-07-11
得票数 1
回答已采纳
1
回答
循环遍历文件并用不同的文本删除几行
、
、
、
file in $FSEFiles) (Get-Content $file.PSPath) | Foreach-Object {
Where-Object
{ $_ -notmatch "16422@" } } |#Foreach-Object {
Where-Object
{ $_ -notma
浏览 1
提问于2014-12-19
得票数 3
回答已采纳
3
回答
Powershell正则表达式与字符串末尾的vhd或vhdx匹配。
、
powershell非常陌生,我正试图编写一个脚本来复制以vhd或vhdx结尾的文件$NEWEST_VHD = Get-ChildItem -Path $vhdSourceDir |
Where-Object
失败尝试
Where-Object
Name -like ".vhdx?"
Where-Object
Name -match ".
Where-Object</em
浏览 2
提问于2015-04-08
得票数 2
2
回答
列出在PowerShell中具有空描述字段的用户
、
{(Enabled -eq "True" )} -Properties Description $NoDescrUsers = $users |
Where-Object
{$_.Description -eq ""}$NoDescrUsers= $users |
Where-Object
$_.Descri
浏览 6
提问于2017-04-18
得票数 1
回答已采纳
1
回答
替换管道中的文本
function Remove-MergedBranches git branch -a --merged |
Where-Object
{$_ -NotMatch "^\*"} |
Where-Object
{-not ( $_-Like "*develop" )} |
Whe
浏览 3
提问于2016-09-29
得票数 1
1
回答
搜索并获取文件,但如果值传递为空,则忽略代码
、
($basepkg -ne $null -And $pkgtype -eq 'A') Get-ChildItem -Path "F:\temp1\Packages" -Recurse |
Where-Object
{ $_.Name -match $basepkg } |
Where-Object
{ $_.Name -match '`*basetemplate*'} |
Where-Object
{ $_.Name{ $_.Name -match $basepkg }
浏览 13
提问于2019-08-22
得票数 3
回答已采纳
1
回答
在PowerShell中将ojects数组解析为字符串
、
string[]] $computer = Get-ADComputer -properties * -filter {(operatingsystem -like "*Windows 7*")} |
Where-Object
{$_.name -NotLike "V7-*"} |
浏览 0
提问于2018-04-17
得票数 0
回答已采纳
1
回答
在AZURE中的所有SQL数据库中进行标记
、
、
409b-a9ec-0a733b802ad6/resourceGroups/ResourceGroup/providers/Microsoft.Sql/servers/BuyServer/databases |
Where-Object
{$_.Name -notlike '*_Report'} |
Where-Object
{$_.Name -notlike '*_Time'} |
Where-Object
{$_.Name -no
浏览 3
提问于2020-04-04
得票数 0
回答已采纳
1
回答
怎么能在一条线上做到这些,我似乎很难让它起作用。
$NameMatches = $Prices |
Where-Object
'name' -EQ $sub.OfferName $BillingFreqMatches = $TermMatches |
where-object
'ItemCode' -match $BillingFreq
浏览 3
提问于2022-04-06
得票数 0
回答已采纳
1
回答
选择对象表达式powershell中的多个条件
@{Name='IPName';Expression={$_.names -join ' ;'}} $addressesAndNames |
Where-Object
$_.IPName -notlike 'reserved *' |
Where-Object
$_.IPName -notlike 'gateway' |
Where-Object
$_.IPName-Path "E:\ComparisonFiles\InfoBlox_Used_IP
浏览 10
提问于2022-02-08
得票数 0
回答已采纳
1
回答
Where-object
-or不工作
这个脚本运行得很好,直到我在
where-object
cmdlet中添加了'or‘语句。$user1 = "John.smith"get-aduser -Filter * |
Where-Object
{{$_.samaccountname -eq "我还尝试避免使用-or,并使用if,else语句:$user2 = "jsmith" $result = Get-ADUser
浏览 0
提问于2016-05-14
得票数 1
点击加载更多
扫码
添加站长 进交流群
领取专属
10元无门槛券
手把手带您无忧上云
相关
资讯
通过 PowerShell 语言助力员工行为管理软件发展
PowerView 渗透测试工具使用方法Part.2
把Windows给印度人做,微软大佬都去搞小工具了
热门
标签
更多标签
云服务器
ICP备案
腾讯会议
云直播
对象存储
活动推荐
运营活动
广告
关闭
领券