Jump to content


Photo

Loading NXGraphic on Visible


  • Please log in to reply
2 replies to this topic

#1 eddy2099

eddy2099
  • Members
  • 4 posts

Posted 20 June 2019 - 12:04 PM

Currently my NextGrid has a NXGraphic column which I am loading up while populating the row using the following code

 

  filelisting.Cell[filelisting.columns.itemby['cThumb'].index, xcount].Data := loadthumb(path);

It works great until the app just silently close without error when I get to about 9500 + rows. Without loading up the graphics, I have no issues with loading a larger list. 

 

I know this is probably not ideal and was wondering if there is a way to do only load on the rows which are visible in view and unload them when the user scrolls away from those visible rows in the grid. 

 

Is there any codes which could implement this ? It definitely would be great. 

 

Thanks.

 



#2 Boki (Berg)

Boki (Berg)

    Boki (Berg)

  • Forum Admin
  • PipPipPipPipPip
  • 8,191 posts
  • Gender:Male

Posted 20 June 2019 - 07:15 PM

Hello,

 

Maybe you can use OnVerticalScroll event and then use FirstRowInPage and LastRowInPage properties of a view.

 

That way after scrolling you can update rows from 1st on page to last. But anyway all should work fine with your code as Grid only displays images and nothing else. Maybe there is a some bug that I can fix? If you maybe can build me mini demo (not sure how to have 9000 pictures :)) and I can try it. Maybe there are some memory leaks.


boki@bergsoft.net | LinkedIn Profile
--
BergSoft Home Page: www.bergsoft.net
Users Section: users.bergsoft.net
Articles and Tutorials: help.bergsoft.net (Developers Network)
--
BergSoft Facebook page
--
Send us applications made with our components and we will submit them on: www.bergsoft.net/apps.htm. Link to this page will be also set on home page too.

#3 eddy2099

eddy2099
  • Members
  • 4 posts

Posted 21 June 2019 - 03:32 AM

I actually did a small demo just populating the same picture on all the row and it seems to go on. Perhaps there is something else at play here. Will test more and let you know.

 

In my project's grid there are a number of columns but those are just text so would not have affected anything.

 

Thanks.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users