0
在使用圆整函数后,我无法在PowerShell中创建位图。有人能帮助我吗 ?无法在整数后创建位图
$newWidth = [Math]::Round($idealWidth * $ratioOriginal);
$bmpResized = New-Object System.Drawing.Bitmap($newWidth, 800)
我得到:Exception calling ".ctor" with "2" argument(s): "Parameter is not valid."
这将工作New-Object System.Drawing.Bitmap(800, 800)
,但我需要计算一个新的宽度。