I am still a beginner with Powershell and I am trying to create a Windows Forms application.
This is what I need: a toolstripcombobox, where its items are updated according to a variable.
Let me show you a summary:
$Location = dir *.txt | select Basename
I have 2 textfiles in the same directory as the Powershell script, called File1.txt and File2.txt.
I would like my combobox items to have the name of those files, but instead they always appear as
How can I make them to be called simply File1 and File2?