Hi, Add can only be called after a Begin, but before an End. Like this:
Begin Add Add Add ... End The dataset is added at the End call. What you are trying to do can be done using IupPlotInsert instead. Best, Scuri Em ter., 13 de out. de 2020 às 07:31, Ulrich Schmidt <u.sch...@gmx.de> escreveu: > > Am 13.10.2020 um 10:35 schrieb Ulrich Schmidt: > > > > i use a iup.timer interrupt to read new values every second and try to > > display them: > > > > local s = comPort:read(64, 600); > > if s ~= "" then > > messages.append = s; > > plot:Add(plotX, tonumber(s:match("%d+"))); > > plotX = plotX + 1; > > plot.redraw = "CURRENT"; > > end; > > As i figured out meanwhile the "plot:Add(..)" statement crashes silently. > The next statement "plotX = plotX + 1;" does not become executed, hence > the plot.redraw statement will not be executed too. > > Ulrich. > > > _______________________________________________ > Iup-users mailing list > Iup-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/iup-users >
_______________________________________________ Iup-users mailing list Iup-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/iup-users