[System.Reflection.Assembly]::LoadWithPartialName("System.windows.Forms")
$form = new-object "System.Windows.Forms.Form"
$form.Size = new-object System.Drawing.Size @(200,200)
$Bereich = new-object "System.Windows.Forms.TableLayoutPanel"
$Bereich.Dock = "Fill"
$Bereich.RowCount = 2
$Bereich.ColumnCount = 2
$Bereich.RowStyles.Add(new RowStyle(SizeType.Percent, 33.33333F))
$form.Controls.Add($Bereich)
$form.showdialog()
Has anyone an idea?
The oddity seems to be the above line. I've never used that before.
I've not spent much time on it, but I'll try to look at it again if
you're not in a big rush. It could only be tomorrow night though.
Marco
--
Microsoft MVP - Windows PowerShell
http://www.microsoft.com/mvp
PowerGadgets MVP
http://www.powergadgets.com/mvp
[System.Reflection.Assembly]::LoadWithPartialName("System.windows.Forms")
$form = new-object "System.Windows.Forms.Form"
$form.Size = new-object System.Drawing.Size @(200,200)
$Bereich = new-object "System.Windows.Forms.TableLayoutPanel"
$Bereich.Dock = "Fill"
$Bereich.CellBorderStyle = "Single"
$Bereich.RowCount = 2
$Bereich.ColumnCount = 2
$Bereich.RowStyles.Add((new-object
System.Windows.Forms.RowStyle([System.Windows.Forms.SizeType]::Percent, 50)))
$Bereich.RowStyles.Add((new-object
System.Windows.Forms.RowStyle([System.Windows.Forms.SizeType]::Percent, 50)))
$Bereich.ColumnStyles.Add((new-object
System.Windows.Forms.ColumnStyle([System.Windows.Forms.SizeType]::Percent,
50)))
$Bereich.ColumnStyles.Add((new-object
System.Windows.Forms.ColumnStyle([System.Windows.Forms.SizeType]::Percent,
50)))
$form.Controls.Add($Bereich)
$form.showdialog()