----- CODE
function avanzar ()
pos = Progress.GetCurrentPos("Plugin1");
if pos == 100 then pos = 1
else pos = pos + 10 end
Progress.SetCurrentPos("Plugin1", pos);
return true;
end
Progress.SetText("Plugin1", "");
Progress.SetCurrentPos("Plugin1", 0);
Progress.SetRange("Plugin1", 0, 100);
Plugin.SetVisible("Plugin1", true);
bshowFindtext = true;
while bshowFindtext do
Progress.SetText("Plugin1", "Searching");
a = File.Find("E:\\", "*.mp3", true, false, nil, avanzar);
bshowFindtext = false;
end
howmany = Table.Count(a); ----- PROBLEM LINE 26
Progress.SetText("Plugin1", "Sorting...");
for k in a do
data = a[k];
name = a[k];
ListBox.AddItem("ListBox1", name, data);
pgresspos = ((k / howmany) * 100);
Progress.SetCurrentPos("Plugin1", pgresspos);
if k == howmany then
Plugin.SetVisible("Plugin1", false);
end
end
----- END
Doesnt work because problem line 26 howmany = Table.Count(a);
function avanzar ()
pos = Progress.GetCurrentPos("Plugin1");
if pos == 100 then pos = 1
else pos = pos + 10 end
Progress.SetCurrentPos("Plugin1", pos);
return true;
end
Progress.SetText("Plugin1", "");
Progress.SetCurrentPos("Plugin1", 0);
Progress.SetRange("Plugin1", 0, 100);
Plugin.SetVisible("Plugin1", true);
bshowFindtext = true;
while bshowFindtext do
Progress.SetText("Plugin1", "Searching");
a = File.Find("E:\\", "*.mp3", true, false, nil, avanzar);
bshowFindtext = false;
end
howmany = Table.Count(a); ----- PROBLEM LINE 26
Progress.SetText("Plugin1", "Sorting...");
for k in a do
data = a[k];
name = a[k];
ListBox.AddItem("ListBox1", name, data);
pgresspos = ((k / howmany) * 100);
Progress.SetCurrentPos("Plugin1", pgresspos);
if k == howmany then
Plugin.SetVisible("Plugin1", false);
end
end
----- END
Doesnt work because problem line 26 howmany = Table.Count(a);
Comment