DatagridView only showing 1 result

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.
This topic is 2 years and 8 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
Locked
User avatar
localpct
Posts: 397
Last visit: Thu Oct 27, 2022 5:57 am

DatagridView only showing 1 result

Post by localpct »

My DGVs are only showing one no matter how many rows are in my CSV file. It's clearly reading the data fine, but not looping to the next result.

Here is my CSV with the form results
Snag_694094.png
Snag_694094.png (20.07 KiB) Viewed 6220 times
I've included my PSF, but removed the .csv location
DummyDGV.psf
(32.73 KiB) Downloaded 293 times
Please help lol
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: DatagridView only showing 1 result

Post by jvierra »

Look at the documents here: https://info.sapien.com/index.php/guis/ ... ZpZXciXQ==

ITHey will teach you how to load a DGV.
User avatar
localpct
Posts: 397
Last visit: Thu Oct 27, 2022 5:57 am

Re: DatagridView only showing 1 result

Post by localpct »

Hi, the issue lies within the job

Posted my psf in hopes someone could check it out. It’s very minimal for sharing :)
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: DatagridView only showing 1 result

Post by jvierra »

There is no need to use a job to load a simple CSV. JUst read the link to see how to load a CSV.
User avatar
localpct
Posts: 397
Last visit: Thu Oct 27, 2022 5:57 am

Re: DatagridView only showing 1 result

Post by localpct »

I made it simple for this example :) In my actual form, I have a function that runs against 10 varying machines throughout the days
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: DatagridView only showing 1 result

Post by jvierra »

It still does not require a job. Why make your task complex beyond your skill level and beyond what is needed to just load a CSV file.
User avatar
localpct
Posts: 397
Last visit: Thu Oct 27, 2022 5:57 am

Re: DatagridView only showing 1 result

Post by localpct »

Odd. If you care I figured it out. Had nothing to do with my skill level lol

I do like you and you're super smart but man, if you go back to all my previous posts while some might be stupid or silly. I've figured them out and continue growing while you keep saying it's my skill level.

I'm sure there'll be another item I need help figuring out but for now, I'm lucky enough to go catch fireflys with my daughter. Take Care sir.
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: DatagridView only showing 1 result

Post by jvierra »

The issue with your code as posted is that you are sending an array to an array.

Do this:

ArgumentList = ,$ComputerList

This will force the array from the CS to be wrapped in another array.
jvierra
Posts: 15439
Last visit: Tue Nov 21, 2023 6:37 pm
Answers: 30
Has voted: 4 times
Been upvoted: 33 times

Re: DatagridView only showing 1 result

Post by jvierra »

localpct wrote: Thu Jul 01, 2021 6:25 pm Odd. If you care I figured it out. Had nothing to do with my skill level lol

I do like you and you're super smart but man, if you go back to all my previous posts while some might be stupid or silly. I've figured them out and continue growing while you keep saying it's my skill level.

I'm sure there'll be another item I need help figuring out but for now, I'm lucky enough to go catch fireflys with my daughter. Take Care sir.
THe issue isa that ypoour question was way too vgaue and no CSV to tewst with. Please, whenh you ask a question, be sure your example can be executed without causing the person trying to help you have to spend 20 minutes trying to understand the question and invent a CSV or any other data.

I do appologize for not seeing your obvious mistake in passing the ArgumentList.

I too am going out to chase fireflies as they are now coming in batches of bunches.
This topic is 2 years and 8 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
Locked