260260// Allow user to choose the folder containing the experiment files and start the process.
261261Function StartMultiExperimentProcessWrapper ()
262262
263- string message, settingsFile, inputFolder, outputFolder, files
263+ string message, settingsFile, inputFolder, outputFolder
264264 variable jsonID
265265
266266 STRUCT MultiExperimentProcessPrefs prefs
@@ -296,7 +296,7 @@ Function StartMultiExperimentProcessWrapper()
296296 outputFolder = S_Path
297297 ASSERT ( V_flag, "Invalid path" )
298298
299- WAVE /Z files = GetAllFilesRecursivelyFromPath ( "MultiExperimentInputFolder" , regex = "(?i)\. pxp$" )
299+ WAVE /T/ Z files = GetAllFilesRecursivelyFromPath ( "MultiExperimentInputFolder" , regex = "(?i)\. pxp$" )
300300
301301 if ( WaveExists ( files))
302302 Sort / A=2 files, files
@@ -312,10 +312,10 @@ Function StartMultiExperimentProcessWrapper()
312312 JSON_AddVariable ( jsonID, "/processed" , 0 )
313313 JSON_AddVariable ( jsonID, "/errors" , 0 )
314314 JSON_AddVariable ( jsonID, "/skipped" , 0 )
315- JSON_AddVariable ( jsonID, "/total" , DimSize ( inputPXPs , ROWS))
315+ JSON_AddVariable ( jsonID, "/total" , DimSize ( files , ROWS))
316316
317317 JSON_AddTreeArray ( jsonID, "/log" )
318- JSON_AddObjects ( jsonID, "/log" , objCount = DimSize ( inputPXPs , ROWS))
318+ JSON_AddObjects ( jsonID, "/log" , objCount = DimSize ( files , ROWS))
319319
320320 prefs. settingsFile = outputFolder + "conversion.json"
321321 StoreJSON ( prefs, jsonID)
0 commit comments