CSV to Data Table Coder Application

Ask your Windows PowerShell-related questions, including questions on cmdlet development!
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.
User avatar
jsira2003@yahoo.com
Posts: 109
Joined: Fri Apr 07, 2017 9:47 am

CSV to Data Table Coder Application

Post by jsira2003@yahoo.com » Fri May 10, 2019 5:18 pm

I wrote a csv to data table coder application. Needless to say it does all the heavy lifting and saves you a tremendous amount of time making your data a part of your application. It is free and it is on our website www.siraoops.com. It was created with powershell studio.

The link: <removed because it is an executable>

John

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

Re: CSV to Data Table Coder Application

Post by jvierra » Fri May 10, 2019 6:20 pm

The following function is already part of PowerShell Studio,

$csv = Import-Csv myfile.csv
$dt = ConvertTo-Datatable $csv


This code has been part of PowerShell Studio for many years. It can convert any object collection including a CSV to a data table. It does the conversion flawlessly for any CSV you can find.

Can you tell us what issue you are having when converting objects to tables?

User avatar
jsira2003@yahoo.com
Posts: 109
Joined: Fri Apr 07, 2017 9:47 am

Re: CSV to Data Table Coder Application

Post by jsira2003@yahoo.com » Fri May 10, 2019 7:19 pm

What is interesting about this about 6 months ago I had a discussion with someone at this website about incorporating a csv file into a data table and was shown the code and I had to manually type the data in for each record. I did that once and I thought I could automate this process. Then I realized that needed the same thing again and decided to write the application.

The point of this application is that you no longer need the csv file. It generates the code for every record. Then you just plug the code into your app. My program write the data table code. I do quite a bit of coding where I want to include the data into the application and completely eliminate the csv file.

All i can say it is works, glad I wrote it and I wanted to share it.

John

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

Re: CSV to Data Table Coder Application

Post by jvierra » Fri May 10, 2019 7:32 pm

I don't understand. How can you write a CSV converter that doesn't use a CSV file?

The ConvertTo-DataTable can convert any object collection into a data table. What is it that your code does differently?

If you can describe the advantages then do so.

Posting a link to an MSI is not a good way to distribute your idea. The MSI can have malware I n it. How would we know?

If you have a script that can do this then post the script. If you have a project then publish it to GitHub as source and let others compile it if needed. Posting unverified EXE or MSI files is very dangerous and suspicious.

User avatar
jsira2003@yahoo.com
Posts: 109
Joined: Fri Apr 07, 2017 9:47 am

Re: CSV to Data Table Coder Application

Post by jsira2003@yahoo.com » Fri May 10, 2019 7:44 pm

You supply the csv file. It create the actual code with the data! Then you can throw away the csv file! That was the plan. There are times when you just don't want the csv file. The program takes the actual csv file data and build the code around it.

User avatar
jsira2003@yahoo.com
Posts: 109
Joined: Fri Apr 07, 2017 9:47 am

Re: CSV to Data Table Coder Application

Post by jsira2003@yahoo.com » Fri May 10, 2019 7:45 pm

our msi is signed. That is the best can do.

John

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

Re: CSV to Data Table Coder Application

Post by jvierra » Fri May 10, 2019 8:05 pm

"our" - who is "our". Are you a registered company? Is this just an ad for a product? This is not a good forum for posting code that you want to distribute and we do not accepts posts of EXEs and MSI files.

If you have a script that does something useful then feel free to post your script.

User avatar
jsira2003@yahoo.com
Posts: 109
Joined: Fri Apr 07, 2017 9:47 am

Re: CSV to Data Table Coder Application

Post by jsira2003@yahoo.com » Fri May 10, 2019 8:19 pm

Actually as I said, this is a free program that writes powershell code. I wrote it and thought it was nice to share. If you think it's in poor taste remove my posts. I thought it is something quite useful that the functions you describe cannot do.

John

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

Re: CSV to Data Table Coder Application

Post by jvierra » Fri May 10, 2019 8:28 pm

If you want to post your script then do that but posting executables is not allowed.

User avatar
jsira2003@yahoo.com
Posts: 109
Joined: Fri Apr 07, 2017 9:47 am

Re: CSV to Data Table Coder Application

Post by jsira2003@yahoo.com » Fri May 10, 2019 8:41 pm

well the program is actually on the technet gallery. If anyone is interested they can do a google search csv to data table coder and you will go right to it. I created the code and it has been digitally signed. We are going to use the code to import csv data sets directly into our application and do away with the csv files.

thanks for your consideration,

John

Locked