diff --git a/Wardrobe/Gratings Data/Database.vb b/Wardrobe/Gratings Data/Database.vb index 614bc50..620b3bc 100644 --- a/Wardrobe/Gratings Data/Database.vb +++ b/Wardrobe/Gratings Data/Database.vb @@ -8,6 +8,32 @@ Public Class Database Dim excelApp As Excel.Application = New Excel.Application Dim excelWB As Excel.Workbook + + ' --- READ EXCEL FILE DATA FROM .TXT FILES --- + 'Dim excelData As String() = System.IO.File.ReadAllLines("C:\Users\Anton\Documents\Exjobb\Inspo\excelData.txt") + + 'excelWB = excelApp.Workbooks.Open("C:\Users\Anton\Documents\Exjobb\Inspo\loadData.xlsx") + 'Dim activeSheet As Excel.Worksheet + 'activeSheet = excelWB.Sheets(1) + + 'For i = 0 To excelData.Length - 1 + ' If i Mod 2 = 1 Then + ' Dim words As String() = excelData(i).Split(" ") + ' For j = 1 To words.Length - 1 + ' activeSheet.Cells(Math.Floor(i / 2) + 1, j).Value = words(j) + ' Next + ' End If + 'Next + + 'excelWB.Save() + + 'excelWB.Close() + 'excelApp.Quit() + 'System.Runtime.InteropServices.Marshal.ReleaseComObject(excelWB) + 'System.Runtime.InteropServices.Marshal.ReleaseComObject(excelApp) + + + ' Make .csv files of each sheet in Excel excelApp.DisplayAlerts = False Dim wSNames As New List(Of String)