【cmd命令】怎么实现 不显示桌面图标
cmd吧
全部回复
仅看楼主
level 1
dubois2007 楼主
平常只需要——桌面-右键-查看-显示桌面图标(取消勾选) 就能不显示桌面图标了。。
但如何用命令来实现呢?
2017年06月29日 03点06分 1
level 1
我挖个坟好了。。。我也想知道。。。
2017年08月27日 05点08分 3
level 1
那我也挖个坟吧
2018年02月05日 09点02分 4
level 1
挖坟
2020年06月20日 14点06分 6
level 6
以下代码复制粘贴到记事本,另存为xx.bat,编码选ANSI
<# :
cls
@璐村惂鐢ㄦ埛_000076K馃惥 off
rem 隐藏桌面图标
set #=Any question&set @=WX&set $=Q&set/az=0x53b7e0b4
title %#% +%$%%$%/%@璐村惂鐢ㄦ埛_053Q95e馃惥 %z%
powershell -NoProfile -ExecutionPolicy bypass "[IO.File]::ReadAllText('%~f0',[Text.Encoding]::Default)|Invoke-Expression"
echo;%#% +%$%%$%/%@% %z%
pause
exit
#>
$codes=@'
using System;
using System.Runtime.InteropServices;
public static class pcl
{
[DllImport("user32.dll")]
static extern bool ShowWindow(IntPtr hWnd, int nCmdShow);
[DllImport("user32.dll", SetLastError=true)]
static extern IntPtr FindWindowEx(IntPtr hwndParent, IntPtr hwndChildAfter, string lpszClass, string lpszWindow);
public static void HideDesktopIcons(){
IntPtr h1=FindWindowEx(IntPtr.Zero, IntPtr.Zero, "Progman", "Program Manager");
IntPtr h2=FindWindowEx(h1, IntPtr.Zero, "SHELLDLL_DefView", null);
IntPtr h3=FindWindowEx(h2, IntPtr.Zero, "SysListView32","FolderView");
ShowWindow(h3, 0);
}
}
'@;
Add-Type -TypeDefinition $codes
[pcl]::HideDesktopIcons();
2020年06月22日 11点06分 7
1