dart_pdf icon indicating copy to clipboard operation
dart_pdf copied to clipboard

hang when data is too large

Open Vish88781 opened this issue 1 year ago • 3 comments

When I load 2000 rows with 5 columns of data, my Flutter app hangs for seconds.

can we use compute for forloop functionality

kind of any indication that not hang the app and show users that the event is in process

Vish88781 avatar Feb 06 '24 13:02 Vish88781

When you solve please inform us . Good luck .

bksbora avatar Feb 07 '24 15:02 bksbora

@bksbora Ok

Vish88781 avatar Feb 08 '24 07:02 Vish88781

I haven't tried it before but this is the solution that came to my mind. Can you create a addRowFunction and create your proccesed data before open pdf then pass to pdf ? like there just pass the tableRowList :

List<pw.TableRow> tableRowList = [];
 if (guillotines[sistemNo].ustclasicGiyotinYanKasaProfilKullanilacakMiktar != 0) {
          addRowFuction(
            guillotines[sistemNo].ustclasicGiyotinYanKasaProfilRef,
            'ustclasicGiyotinYanKasaProfilRef',
          );
        }
        
        

bksbora avatar Mar 21 '24 14:03 bksbora