使用powershell构建gui界面:
参考:
https://blog.csdn.net/gjmjack/article/details/124032293
c
# Create a new button instance
$button1 = New-Object System.Windows.Forms.Button;
# Set button property
$button1.Location = New-Object System.Drawing.Point(257, 150);
$button1.Name = "button1";
$button1.Size = New-Object System.Drawing.Size(284, 103);
$button1.TabIndex = 0;
$button1.Text = "工作使我快乐";
$button1.UseVisualStyleBackColor = $true;
无法运行.ps1脚本(powershell脚本)处理办法:
参考:
https://blog.csdn.net/gao_zhennan/article/details/131719371
c
Get-ExecutionPolicy -List
Set-ExecutionPolicy -ExecutionPolicy AllSigned CurrentUser
Get-ExecutionPolicy -List