Quote:
+ ReaScript: support changing the returned field separator in GetUserInputs function
|
Oh many thanks !
Very good start: if the character can be encoded in a single byte it works.
Code:
separator = "#"
retval, retvals_csv = reaper.GetUserInputs("Title", 2, "CSV 1, CSV2,separator=" .. separator, '')
if retval then
t = {}
i = 0
for line in retvals_csv:gmatch("[^" .. separator .. "]*") do
i = i + 1
t[i] = line
end
end
It seems to work with new line character which is quite good in this case as fields are single line.
But it breaks with null character
(it doesn't add null characters to the returned string).