You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
using namespace Terminal.Gui
Add-Type -path $PSScriptRoot\NStack\netstandard2.0\NStack.dll
Add-Type -Path $PSScriptRoot\Terminal.Gui\netstandard2.1\Terminal.Gui.dll
function verb-noun {
[cmdletbinding()]
[Alias('vn')]
param()
[Application]::Init()
[Application]::QuitKey = 'Esc'
$window = [Window]@{
Title = "My Window Title"
}
$lblHello = [Label]@{
#X and Y are relative positions in the window
X = 1
Y = 1
Text = 'Hello World'
}
window.Add($lblHello)
}
When I run this... I get Line | 4 | Add-Type -Path $PSScriptRoot\Terminal.Gui\netstandard2.1\Terminal.Gui … | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | Could not load file or assembly 'Terminal.Gui, Version=1.0.0.0, Culture=neutral, | PublicKeyToken=e2bd4b710393a695'. Assembly with same name is already loaded
When I comment out the Terminal.Gui command... it just "runs" and returns me back to the command line.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
When I run this... I get
Line | 4 | Add-Type -Path $PSScriptRoot\Terminal.Gui\netstandard2.1\Terminal.Gui … | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | Could not load file or assembly 'Terminal.Gui, Version=1.0.0.0, Culture=neutral, | PublicKeyToken=e2bd4b710393a695'. Assembly with same name is already loadedWhen I comment out the Terminal.Gui command... it just "runs" and returns me back to the command line.
Thoughts?
Beta Was this translation helpful? Give feedback.
All reactions