c# - UWP windows 10 app memory increasing on scroll listview and add item at the bottom of listview -


i have uwp windows 10 app , noticed memory using app increase when new items add @ end of listview, memory increase around 4mb each item.

i found increasing memory because of item template set them. used usercontrol item template contain button , textblock , 1 image.

how can remove item not on screen visible memory ?

the user control similar :

<usercontrol     x:class="xamlpulltorefresh.myusercontrol"     xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"     xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"     xmlns:local="using:xamlpulltorefresh"     xmlns:d="http://schemas.microsoft.com/expression/blend/2008"     xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"     mc:ignorable="d"     d:designheight="300"     d:designwidth="400">      <grid>         <grid.rowdefinitions>             <rowdefinition />             <rowdefinition />             <rowdefinition />         </grid.rowdefinitions>         <grid.columndefinitions>             <columndefinition />             <columndefinition />         </grid.columndefinitions>          <image source="{binding myobject.imageurl}" />         <textblock grid.column="1" text="{binding myobject.name}" />         <textblock grid.row="1" grid.columnspan="2" text="{binding myobject.text}" />         <stackpanel grid.row="2" grid.columnspan="2" orientation="horizontal" horizontalalignment="center">             <button margin="10"/>             <button margin="10"/>             <button margin="10"/>         </stackpanel>     </grid> </usercontrol> 


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

How to get the ip address of VM and use it to configure SSH connection dynamically in Ansible -

javascript - Get parameter of GET request -