Combobox Jobs to push applicaitons remotely

Ask questions about creating Graphical User Interfaces (GUI) in PowerShell and using WinForms controls.
Forum rules
Do not post any licensing information in this forum.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
Post Reply
User avatar
localpct
Posts: 295
Joined: Wed Sep 09, 2015 12:53 pm

Combobox Jobs to push applicaitons remotely

Post by localpct » Thu Oct 10, 2019 6:51 am

I'm trying to create a gui that allows us to use a combobox to push applications

I have the Name and Value ( folder ) of the applications in a CSV
The app loads the CSV file

But I'm trying to simplify my code as so I'm not writing if ($combobox.SelectedItem -eq 'SomeApplicationName') for each app, as that's not very automated
I need it to feed from my CSV file
MainFormShare.psf
(71.03 KiB) Downloaded 5 times

User avatar
jvierra
Posts: 13802
Joined: Tue May 22, 2007 9:57 am
Contact:

Re: Combobox Jobs to push applicaitons remotely

Post by jvierra » Thu Oct 10, 2019 7:12 am

Sorry but there is no way to run your form as it is system depe3ndent.
What do you mean that you need to feed from a CSV? Just load the CSV into the ComboBox and use the values as selected.

$combobox.DataSource = [arraylist](Import-Csv <yourcsv>)

Now just refer to the name in the selected row of the CSV.

$combobox.Selected.Item.AppName

User avatar
localpct
Posts: 295
Joined: Wed Sep 09, 2015 12:53 pm

Re: Combobox Jobs to push applicaitons remotely

Post by localpct » Thu Oct 10, 2019 2:20 pm

I was able to resolve

Post Reply